Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
eae0dda3
Kaydet (Commit)
eae0dda3
authored
Ara 08, 2014
tarafından
Caolán McNamara
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Resolves: fdo#86820 executing toolbar menu entry can destroy menu
Change-Id: Ide0ea8f8ff145d487e409b0091918b59f1f83405
üst
848adf43
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
4 deletions
+11
-4
toolbarmanager.cxx
framework/source/uielement/toolbarmanager.cxx
+11
-4
No files found.
framework/source/uielement/toolbarmanager.cxx
Dosyayı görüntüle @
eae0dda3
...
...
@@ -1792,17 +1792,24 @@ IMPL_LINK( ToolBarManager, Command, CommandEvent*, pCmdEvt )
// overflow and context menus). If we set these Hdls permanently rather
// than just when the context menu is showing, then events are duplicated
// when the menu is being used as an overflow menu.
m_pToolBar
->
GetMenu
()
->
SetSelectHdl
(
LINK
(
this
,
ToolBarManager
,
MenuSelect
)
);
m_pToolBar
->
GetMenu
()
->
SetDeactivateHdl
(
LINK
(
this
,
ToolBarManager
,
MenuDeactivate
)
);
Menu
*
pManagerMenu
=
m_pToolBar
->
GetMenu
();
pManagerMenu
->
SetSelectHdl
(
LINK
(
this
,
ToolBarManager
,
MenuSelect
)
);
pManagerMenu
->
SetDeactivateHdl
(
LINK
(
this
,
ToolBarManager
,
MenuDeactivate
)
);
// make sure all disabled entries will be shown
pMenu
->
SetMenuFlags
(
pMenu
->
GetMenuFlags
()
|
MENU_FLAG_ALWAYSSHOWDISABLEDENTRIES
);
::
Point
aPoint
(
pCmdEvt
->
GetMousePosPixel
()
);
pMenu
->
Execute
(
m_pToolBar
,
aPoint
);
//fdo#86820 We may have been disposed and so have a NULL m_pToolBar by
//executing a menu entry, e.g. inserting a chart replaces the toolbars
pManagerMenu
=
m_bDisposed
?
NULL
:
m_pToolBar
->
GetMenu
();
if
(
pManagerMenu
)
{
// Unlink our listeners again -- see above for why.
m_pToolBar
->
GetMenu
()
->
SetSelectHdl
(
Link
()
);
m_pToolBar
->
GetMenu
()
->
SetDeactivateHdl
(
Link
()
);
pManagerMenu
->
SetSelectHdl
(
Link
()
);
pManagerMenu
->
SetDeactivateHdl
(
Link
()
);
}
}
return
0
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment