Skip to content
Permalink
Browse files

When a panel widget opens a new panel, the new panel should inherit

the dock mode of the previous panel

(cherry-picked from 01ec0e4)
  • Loading branch information
nyalldawson committed Sep 14, 2016
1 parent a7492f5 commit 1accdda11e603b560c3166737c1d7a5be78a629a
Showing with 3 additions and 2 deletions.
  1. +3 −0 src/gui/qgspanelwidget.cpp
  2. +0 −2 src/gui/symbology-ng/qgsrulebasedrendererv2widget.cpp
@@ -62,6 +62,9 @@ QgsPanelWidget*QgsPanelWidget::findParentPanel( QWidget* widget )

void QgsPanelWidget::openPanel( QgsPanelWidget* panel )
{
//panel dock mode inherits from this panel
panel->setDockMode( dockMode() );

if ( mDockMode )
{
emit showPanel( panel );
@@ -258,7 +258,6 @@ void QgsRuleBasedRendererV2Widget::refineRuleCategoriesGui( const QModelIndexLis
QgsCategorizedSymbolRendererV2Widget* w = new QgsCategorizedSymbolRendererV2Widget( mLayer, mStyle, nullptr );
w->setPanelTitle( tr( "Add categories to rules" ) );
connect( w, SIGNAL( panelAccepted( QgsPanelWidget* ) ), this, SLOT( refineRuleCategoriesAccepted( QgsPanelWidget* ) ) );
w->setDockMode( this->dockMode() );
w->setMapCanvas( mMapCanvas );
openPanel( w );
}
@@ -269,7 +268,6 @@ void QgsRuleBasedRendererV2Widget::refineRuleRangesGui( const QModelIndexList& )
w->setPanelTitle( tr( "Add ranges to rules" ) );
connect( w, SIGNAL( panelAccepted( QgsPanelWidget* ) ), this, SLOT( refineRuleRangesAccepted( QgsPanelWidget* ) ) );
w->setMapCanvas( mMapCanvas );
w->setDockMode( this->dockMode() );
openPanel( w );
}

0 comments on commit 1accdda

Please sign in to comment.
You can’t perform that action at this time.