Changeset View
Changeset View
Standalone View
Standalone View
src/KGantt/kganttview.cpp
Show First 20 Lines • Show All 352 Lines • ▼ Show 20 Line(s) | |||||
353 | */ | 353 | */ | ||
354 | void View::setGraphicsView( GraphicsView* gv ) | 354 | void View::setGraphicsView( GraphicsView* gv ) | ||
355 | { | 355 | { | ||
356 | if ( gv != d->gfxview ) { | 356 | if ( gv != d->gfxview ) { | ||
357 | GraphicsView* old = d->gfxview; | 357 | GraphicsView* old = d->gfxview; | ||
358 | d->gfxview = gv; | 358 | d->gfxview = gv; | ||
359 | d->gfxview->setModel(old->model()); // use the old ForwardingProxyModel | 359 | d->gfxview->setModel(old->model()); // use the old ForwardingProxyModel | ||
360 | d->setupGraphicsView(); | 360 | d->setupGraphicsView(); | ||
361 | d->gfxview->setGrid( old->grid() ); | 361 | d->gfxview->setGrid( old->takeGrid() ); | ||
362 | delete old; | 362 | delete old; | ||
363 | } | 363 | } | ||
364 | } | 364 | } | ||
365 | 365 | | |||
366 | /*! | 366 | /*! | ||
367 | * \returns a pointer to the GraphicsView | 367 | * \returns a pointer to the GraphicsView | ||
368 | */ | 368 | */ | ||
369 | const GraphicsView* View::graphicsView() const | 369 | const GraphicsView* View::graphicsView() const | ||
▲ Show 20 Lines • Show All 296 Lines • Show Last 20 Lines |