diff options
author | Uray M. János <uray.janos@gmail.com> | 2012-07-24 11:29:57 +0200 |
---|---|---|
committer | Andras Timar <atimar@suse.com> | 2012-08-10 21:51:25 +0200 |
commit | c0dd0edf2af6a3cd9fb2d71cc2a3ba14a22b855b (patch) | |
tree | aed43dbac24aa44b0fca71d6b9537474090037f8 /basctl | |
parent | 98277b849424b9b4f486b8deb00db0c47487267e (diff) |
fdo#50633 IDE: select current module in Object Catalog on open
Change-Id: Ieea731b0ed8eefdab616ed1f778b445aae14191c
Signed-off-by: Andras Timar <atimar@suse.com>
Diffstat (limited to 'basctl')
-rw-r--r-- | basctl/source/basicide/basides1.cxx | 1 | ||||
-rw-r--r-- | basctl/source/basicide/basidesh.cxx | 6 | ||||
-rw-r--r-- | basctl/source/basicide/objdlg.cxx | 7 | ||||
-rw-r--r-- | basctl/source/basicide/objdlg.hxx | 2 |
4 files changed, 8 insertions, 8 deletions
diff --git a/basctl/source/basicide/basides1.cxx b/basctl/source/basicide/basides1.cxx index 69d773c7c8c1..42f6df458cb3 100644 --- a/basctl/source/basicide/basides1.cxx +++ b/basctl/source/basicide/basides1.cxx @@ -1209,6 +1209,7 @@ void BasicIDEShell::SetCurWindow( IDEBaseWindow* pNewWin, sal_Bool bUpdateTabBar GetViewFrame()->GetWindow().SetHelpId( HID_BASICIDE_MODULWINDOW ); SfxObjectShell::SetCurrentComponent( NULL ); } + pModulLayout->GetObjectCatalog().SetCurrentEntry(pCurWin); SetUndoManager( pCurWin ? pCurWin->GetUndoManager() : 0 ); InvalidateBasicIDESlots(); EnableScrollbars( pCurWin ? sal_True : sal_False ); diff --git a/basctl/source/basicide/basidesh.cxx b/basctl/source/basicide/basidesh.cxx index d2ced7eaf6fa..c53cc8a71362 100644 --- a/basctl/source/basicide/basidesh.cxx +++ b/basctl/source/basicide/basidesh.cxx @@ -552,11 +552,7 @@ void BasicIDEShell::ShowObjectDialog( sal_Bool bShow, sal_Bool bCreateOrDestroy if ( pObjectCatalog ) { pObjectCatalog->SetCancelHdl( LINK( this, BasicIDEShell, ObjectDialogCancelHdl ) ); - BasicEntryDescriptor aDesc; - IDEBaseWindow* pCurWin_ = GetCurWindow(); - if ( pCurWin_ ) - aDesc = pCurWin_->CreateEntryDescriptor(); - pObjectCatalog->SetCurrentEntry( aDesc ); + pObjectCatalog->SetCurrentEntry(pCurWin); } } diff --git a/basctl/source/basicide/objdlg.cxx b/basctl/source/basicide/objdlg.cxx index 7e598de46754..0d112cb038d3 100644 --- a/basctl/source/basicide/objdlg.cxx +++ b/basctl/source/basicide/objdlg.cxx @@ -232,9 +232,12 @@ void ObjectCatalog::UpdateEntries() aMacroTreeList.UpdateEntries(); } -void ObjectCatalog::SetCurrentEntry( BasicEntryDescriptor& rDesc ) +void ObjectCatalog::SetCurrentEntry (IDEBaseWindow* pCurWin) { - aMacroTreeList.SetCurrentEntry( rDesc ); + BasicEntryDescriptor aDesc; + if (pCurWin) + aDesc = pCurWin->CreateEntryDescriptor(); + aMacroTreeList.SetCurrentEntry(aDesc); } ObjectCatalogToolBox_Impl::ObjectCatalogToolBox_Impl( diff --git a/basctl/source/basicide/objdlg.hxx b/basctl/source/basicide/objdlg.hxx index 47e46518bbba..9ed19bd363d3 100644 --- a/basctl/source/basicide/objdlg.hxx +++ b/basctl/source/basicide/objdlg.hxx @@ -75,7 +75,7 @@ public: virtual ~ObjectCatalog(); void UpdateEntries(); - void SetCurrentEntry( BasicEntryDescriptor& rDesc ); + void SetCurrentEntry (IDEBaseWindow* pCurWin); void SetCancelHdl( const Link& rLink ) { aCancelHdl = rLink; } }; |