summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTobias Madl <tobias.madl.dev@gmail.com>2014-11-26 14:53:25 +0000
committerNoel Grandin <noelgrandin@gmail.com>2014-12-01 07:43:31 +0000
commit14596452e781f6a66bcc63b0c447c852df1f2896 (patch)
treec225569f229679084b081021c8c51cfdaf12eb21
parent96ec51292301a105effacfcceec44f696ee6e0f0 (diff)
fdo#84938: replace EVENT_ constants with enum
Change-Id: I8275832d8dae43b374bddd48520d11592e9a6a1f Reviewed-on: https://gerrit.libreoffice.org/13134 Tested-by: LibreOffice gerrit bot <gerrit@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
-rw-r--r--basctl/source/basicide/basicbox.cxx12
-rw-r--r--basctl/source/basicide/baside2b.cxx2
-rw-r--r--basctl/source/basicide/bastypes.cxx2
-rw-r--r--chart2/source/controller/main/ElementSelector.cxx4
-rw-r--r--cui/source/customize/macropg.cxx2
-rw-r--r--cui/source/dialogs/SpellDialog.cxx6
-rw-r--r--cui/source/dialogs/colorpicker.cxx2
-rw-r--r--cui/source/dialogs/hangulhanjadlg.cxx2
-rw-r--r--cui/source/options/connpooloptions.cxx2
-rw-r--r--cui/source/options/optcolor.cxx2
-rw-r--r--cui/source/options/optpath.cxx2
-rw-r--r--cui/source/options/treeopt.cxx2
-rw-r--r--cui/source/tabpages/autocdlg.cxx2
-rw-r--r--cui/source/tabpages/numfmt.cxx2
-rw-r--r--dbaccess/source/ui/app/AppDetailPageHelper.cxx2
-rw-r--r--dbaccess/source/ui/app/AppView.cxx4
-rw-r--r--dbaccess/source/ui/browser/brwview.cxx2
-rw-r--r--dbaccess/source/ui/browser/dataview.cxx8
-rw-r--r--dbaccess/source/ui/control/RelationControl.cxx4
-rw-r--r--dbaccess/source/ui/control/TableGrantCtrl.cxx4
-rw-r--r--dbaccess/source/ui/dlg/ConnectionHelper.cxx4
-rw-r--r--dbaccess/source/ui/misc/WTypeSelect.cxx4
-rw-r--r--dbaccess/source/ui/querydesign/JoinTableView.cxx6
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/TableWindow.cxx4
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowListBox.cxx2
-rw-r--r--dbaccess/source/ui/querydesign/limitboxcontroller.cxx4
-rw-r--r--dbaccess/source/ui/querydesign/querycontainerwindow.cxx2
-rw-r--r--dbaccess/source/ui/relationdesign/RelationDesignView.cxx2
-rw-r--r--dbaccess/source/ui/tabledesign/TEditControl.cxx2
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx2
-rw-r--r--dbaccess/source/ui/tabledesign/TableDesignView.cxx2
-rw-r--r--dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx2
-rw-r--r--desktop/source/deployment/gui/dp_gui_dialog2.cxx4
-rw-r--r--desktop/source/deployment/gui/dp_gui_extlistbox.cxx4
-rw-r--r--extensions/source/bibliography/bibcont.cxx2
-rw-r--r--extensions/source/bibliography/toolbar.cxx4
-rw-r--r--extensions/source/propctrlr/browserlistbox.cxx4
-rw-r--r--extensions/source/propctrlr/browserview.cxx2
-rw-r--r--extensions/source/propctrlr/commoncontrol.cxx2
-rw-r--r--extensions/source/propctrlr/standardcontrol.cxx6
-rw-r--r--extensions/source/propctrlr/standardcontrol.hxx2
-rw-r--r--extensions/source/propctrlr/usercontrol.cxx2
-rw-r--r--filter/source/xsltdialog/xmlfiltersettingsdialog.cxx4
-rw-r--r--forms/source/richtext/richtextvclcontrol.cxx4
-rw-r--r--formula/source/ui/dlg/formula.cxx4
-rw-r--r--formula/source/ui/dlg/funcpage.cxx4
-rw-r--r--formula/source/ui/dlg/funcutl.cxx6
-rw-r--r--fpicker/source/office/iodlg.cxx4
-rw-r--r--framework/source/uielement/comboboxtoolbarcontroller.cxx6
-rw-r--r--framework/source/uielement/edittoolbarcontroller.cxx2
-rw-r--r--framework/source/uielement/spinfieldtoolbarcontroller.cxx2
-rw-r--r--include/vcl/event.hxx51
-rw-r--r--reportdesign/source/ui/dlg/AddField.cxx2
-rw-r--r--reportdesign/source/ui/dlg/CondFormat.cxx4
-rw-r--r--reportdesign/source/ui/report/DesignView.cxx2
-rw-r--r--sc/source/ui/app/inputwin.cxx6
-rw-r--r--sc/source/ui/cctrl/checklistmenu.cxx2
-rw-r--r--sc/source/ui/condformat/condformatdlgentry.cxx2
-rw-r--r--sc/source/ui/miscdlgs/acredlin.cxx2
-rw-r--r--sc/source/ui/miscdlgs/anyrefdg.cxx4
-rw-r--r--sc/source/ui/navipi/navipi.cxx10
-rw-r--r--sc/source/ui/navipi/scenwnd.cxx4
-rw-r--r--sc/source/ui/pagedlg/tphfedit.cxx4
-rw-r--r--sc/source/ui/view/gridwin.cxx10
-rw-r--r--sd/source/ui/animations/CustomAnimationDialog.cxx4
-rw-r--r--sd/source/ui/dlg/RemoteDialogClientBox.cxx4
-rw-r--r--sd/source/ui/dlg/docprev.cxx2
-rw-r--r--sd/source/ui/view/viewshel.cxx2
-rw-r--r--sfx2/source/appl/newhelp.cxx28
-rw-r--r--sfx2/source/control/thumbnailviewitem.cxx4
-rw-r--r--sfx2/source/dialog/backingwindow.cxx4
-rw-r--r--sfx2/source/dialog/basedlgs.cxx12
-rw-r--r--sfx2/source/dialog/dockwin.cxx6
-rw-r--r--sfx2/source/dialog/partwnd.cxx2
-rw-r--r--sfx2/source/dialog/templdlg.cxx4
-rw-r--r--sfx2/source/sidebar/Deck.cxx2
-rw-r--r--sfx2/source/sidebar/PopupContainer.cxx2
-rw-r--r--sfx2/source/sidebar/SidebarToolBox.cxx2
-rw-r--r--sfx2/source/view/frame2.cxx16
-rw-r--r--sfx2/source/view/printer.cxx2
-rw-r--r--sfx2/source/view/userinputinterception.cxx14
-rw-r--r--svtools/source/brwbox/ebbcontrols.cxx10
-rw-r--r--svtools/source/brwbox/editbrowsebox.cxx6
-rw-r--r--svtools/source/contnr/imivctl1.cxx2
-rw-r--r--svtools/source/contnr/simptabl.cxx2
-rw-r--r--svtools/source/control/calendar.cxx2
-rw-r--r--svtools/source/control/fileurlbox.cxx6
-rw-r--r--svtools/source/control/fmtfield.cxx8
-rw-r--r--svtools/source/control/inettbc.cxx6
-rw-r--r--svtools/source/control/roadmap.cxx2
-rw-r--r--svtools/source/control/tabbar.cxx4
-rw-r--r--svtools/source/control/urlcontrol.cxx4
-rw-r--r--svtools/source/dialogs/addresstemplate.cxx2
-rw-r--r--svtools/source/dialogs/prnsetup.cxx2
-rw-r--r--svtools/source/dialogs/wizdlg.cxx2
-rw-r--r--svtools/source/edit/editsyntaxhighlighter.cxx2
-rw-r--r--svtools/source/hatchwindow/ipwin.cxx4
-rw-r--r--svtools/source/table/tabledatawindow.cxx2
-rw-r--r--svtools/source/toolpanel/toolpaneldeck.cxx2
-rw-r--r--svx/source/dialog/rubydialog.cxx2
-rw-r--r--svx/source/fmcomp/gridctrl.cxx2
-rw-r--r--svx/source/form/datanavi.cxx2
-rw-r--r--svx/source/form/tabwin.cxx2
-rw-r--r--svx/source/gallery2/galbrws1.cxx4
-rw-r--r--svx/source/sidebar/tools/PopupContainer.cxx2
-rw-r--r--svx/source/tbxctrls/colrctrl.cxx2
-rw-r--r--svx/source/tbxctrls/grafctrl.cxx6
-rw-r--r--svx/source/tbxctrls/itemwin.cxx32
-rw-r--r--svx/source/tbxctrls/tbcontrl.cxx18
-rw-r--r--svx/source/tbxctrls/tbunocontroller.cxx4
-rw-r--r--svx/source/tbxctrls/tbunosearchcontrollers.cxx4
-rw-r--r--sw/source/ui/dbui/createaddresslistdialog.cxx2
-rw-r--r--sw/source/ui/dbui/mmaddressblockpage.cxx6
-rw-r--r--sw/source/ui/fldui/fldvar.cxx4
-rw-r--r--sw/source/ui/index/cnttab.cxx2
-rw-r--r--sw/source/ui/misc/bookmark.cxx2
-rw-r--r--sw/source/uibase/cctrl/actctrl.cxx2
-rw-r--r--sw/source/uibase/ribbar/workctrl.cxx4
-rw-r--r--vcl/inc/window.h3
-rw-r--r--vcl/osx/salinst.cxx2
-rw-r--r--vcl/source/control/button.cxx6
-rw-r--r--vcl/source/control/combobox.cxx8
-rw-r--r--vcl/source/control/ctrl.cxx4
-rw-r--r--vcl/source/control/field.cxx36
-rw-r--r--vcl/source/control/field2.cxx36
-rw-r--r--vcl/source/control/ilstbox.cxx6
-rw-r--r--vcl/source/control/longcurr.cxx12
-rw-r--r--vcl/source/control/lstbox.cxx6
-rw-r--r--vcl/source/control/scrbar.cxx2
-rw-r--r--vcl/source/control/spinbtn.cxx2
-rw-r--r--vcl/source/control/spinfld.cxx6
-rw-r--r--vcl/source/control/tabctrl.cxx4
-rw-r--r--vcl/source/edit/vclmedit.cxx4
-rw-r--r--vcl/source/window/dialog.cxx8
-rw-r--r--vcl/source/window/dlgctrl.cxx8
-rw-r--r--vcl/source/window/dockwin.cxx4
-rw-r--r--vcl/source/window/event.cxx32
-rw-r--r--vcl/source/window/floatwin.cxx2
-rw-r--r--vcl/source/window/layout.cxx2
-rw-r--r--vcl/source/window/mouse.cxx12
-rw-r--r--vcl/source/window/scrwnd.cxx2
-rw-r--r--vcl/source/window/splitwin.cxx2
-rw-r--r--vcl/source/window/syswin.cxx4
-rw-r--r--vcl/source/window/toolbox.cxx6
-rw-r--r--vcl/source/window/window.cxx14
-rw-r--r--vcl/source/window/winproc.cxx92
-rw-r--r--vcl/win/source/window/salframe.cxx2
148 files changed, 444 insertions, 440 deletions
diff --git a/basctl/source/basicide/basicbox.cxx b/basctl/source/basicide/basicbox.cxx
index 79a60e89a212..9735c597bf01 100644
--- a/basctl/source/basicide/basicbox.cxx
+++ b/basctl/source/basicide/basicbox.cxx
@@ -257,7 +257,7 @@ void LibBox::InsertEntries( const ScriptDocument& rDocument, LibraryLocation eLo
bool LibBox::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
sal_uInt16 nKeyCode = aKeyEvt.GetKeyCode().GetCode();
@@ -279,7 +279,7 @@ bool LibBox::PreNotify( NotifyEvent& rNEvt )
break;
}
}
- else if( rNEvt.GetType() == EVENT_GETFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if ( bFillBox )
{
@@ -287,7 +287,7 @@ bool LibBox::PreNotify( NotifyEvent& rNEvt )
bFillBox = false;
}
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( !HasChildPathFocus(true) )
{
@@ -475,7 +475,7 @@ void LanguageBox::Select()
bool LanguageBox::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nKeyCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
switch( nKeyCode )
@@ -495,10 +495,10 @@ bool LanguageBox::PreNotify( NotifyEvent& rNEvt )
break;
}
}
- else if( rNEvt.GetType() == EVENT_GETFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
}
diff --git a/basctl/source/basicide/baside2b.cxx b/basctl/source/basicide/baside2b.cxx
index 23b03e0dd61b..e1733e16811f 100644
--- a/basctl/source/basicide/baside2b.cxx
+++ b/basctl/source/basicide/baside2b.cxx
@@ -2776,7 +2776,7 @@ void CodeCompleteListBox::KeyInput( const KeyEvent& rKeyEvt )
InsertSelectedEntry();
break;
case KEY_UP: case KEY_DOWN:
- NotifyEvent nEvt( EVENT_KEYINPUT, NULL, &rKeyEvt );
+ NotifyEvent nEvt( MouseNotifyEvent::KEYINPUT, NULL, &rKeyEvt );
PreNotify(nEvt);
break;
}
diff --git a/basctl/source/basicide/bastypes.cxx b/basctl/source/basicide/bastypes.cxx
index 169902a2896c..d0b9fe605b4c 100644
--- a/basctl/source/basicide/bastypes.cxx
+++ b/basctl/source/basicide/bastypes.cxx
@@ -112,7 +112,7 @@ bool BaseWindow::Notify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
KeyEvent aKEvt = *rNEvt.GetKeyEvent();
vcl::KeyCode aCode = aKEvt.GetKeyCode();
diff --git a/chart2/source/controller/main/ElementSelector.cxx b/chart2/source/controller/main/ElementSelector.cxx
index df2c6029d184..31073b103fe4 100644
--- a/chart2/source/controller/main/ElementSelector.cxx
+++ b/chart2/source/controller/main/ElementSelector.cxx
@@ -207,7 +207,7 @@ bool SelectorListBox::Notify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
@@ -230,7 +230,7 @@ bool SelectorListBox::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if ( EVENT_LOSEFOCUS == rNEvt.GetType() )
+ else if ( MouseNotifyEvent::LOSEFOCUS == rNEvt.GetType() )
{
if ( !HasFocus() )
SelectEntryPos( GetSavedValue() );
diff --git a/cui/source/customize/macropg.cxx b/cui/source/customize/macropg.cxx
index c2d44516ca7b..ca978e590b1c 100644
--- a/cui/source/customize/macropg.cxx
+++ b/cui/source/customize/macropg.cxx
@@ -120,7 +120,7 @@ bool MacroEventListBox::Notify( NotifyEvent& rNEvt )
{
bool nRet = Control::Notify( rNEvt );
- if( rNEvt.GetType() == EVENT_GETFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if ( rNEvt.GetWindow() != &maListBox )
maListBox.GrabFocus();
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index 96b59dc53fc2..5bbf6ddce72a 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -988,12 +988,12 @@ bool SpellDialog::Notify( NotifyEvent& rNEvt )
*/
if( IsVisible() && !bFocusLocked )
{
- if( rNEvt.GetType() == EVENT_GETFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
//notify the child window of the focus change
rParent.GetFocus();
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
//notify the child window of the focus change
rParent.LoseFocus();
@@ -1274,7 +1274,7 @@ bool SentenceEditWindow_Impl::PreNotify( NotifyEvent& rNEvt )
{
bool bChange = false;
const TextCharAttrib* pErrorAttrib = 0;
- if(rNEvt.GetType() == EVENT_KEYINPUT)
+ if(rNEvt.GetType() == MouseNotifyEvent::KEYINPUT)
{
const KeyEvent& rKeyEvt = *rNEvt.GetKeyEvent();
bChange = TextEngine::DoesKeyChangeText( rKeyEvt );
diff --git a/cui/source/dialogs/colorpicker.cxx b/cui/source/dialogs/colorpicker.cxx
index 15601c9bee55..540c7bed398a 100644
--- a/cui/source/dialogs/colorpicker.cxx
+++ b/cui/source/dialogs/colorpicker.cxx
@@ -188,7 +188,7 @@ sal_Int32 HexColorControl::GetColor()
bool HexColorControl::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplProcessKeyInput( *rNEvt.GetKeyEvent() ) )
return true;
diff --git a/cui/source/dialogs/hangulhanjadlg.cxx b/cui/source/dialogs/hangulhanjadlg.cxx
index 1391bd57c205..7e02beed6bee 100644
--- a/cui/source/dialogs/hangulhanjadlg.cxx
+++ b/cui/source/dialogs/hangulhanjadlg.cxx
@@ -1365,7 +1365,7 @@ namespace svx
bool SuggestionEdit::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKEvt->GetKeyCode();
diff --git a/cui/source/options/connpooloptions.cxx b/cui/source/options/connpooloptions.cxx
index 7743d8207874..3d432698e0fc 100644
--- a/cui/source/options/connpooloptions.cxx
+++ b/cui/source/options/connpooloptions.cxx
@@ -359,7 +359,7 @@ namespace offapp
bool ConnectionPoolOptionsPage::Notify( NotifyEvent& _rNEvt )
{
- if (EVENT_LOSEFOCUS == _rNEvt.GetType())
+ if (MouseNotifyEvent::LOSEFOCUS == _rNEvt.GetType())
if (m_pTimeout->IsWindowOrChild(_rNEvt.GetWindow()))
commitTimeoutField();
diff --git a/cui/source/options/optcolor.cxx b/cui/source/options/optcolor.cxx
index 67d0890aafce..778b42962821 100644
--- a/cui/source/options/optcolor.cxx
+++ b/cui/source/options/optcolor.cxx
@@ -935,7 +935,7 @@ IMPL_LINK(ColorConfigCtrl_Impl, ScrollHdl, ScrollBar*, pScrollBar)
bool ColorConfigCtrl_Impl::PreNotify( NotifyEvent& rNEvt )
{
- if(rNEvt.GetType() == EVENT_COMMAND)
+ if(rNEvt.GetType() == MouseNotifyEvent::COMMAND)
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
sal_uInt16 nCmd = pCEvt->GetCommand();
diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx
index d231aa10542b..c16535acd725 100644
--- a/cui/source/options/optpath.cxx
+++ b/cui/source/options/optpath.cxx
@@ -167,7 +167,7 @@ bool SvxControlFocusHelper::Notify( NotifyEvent& rNEvt )
{
bool nRet = Control::Notify( rNEvt );
- if ( m_pFocusCtrl && rNEvt.GetWindow() != m_pFocusCtrl && rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( m_pFocusCtrl && rNEvt.GetWindow() != m_pFocusCtrl && rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
m_pFocusCtrl->GrabFocus();
return nRet;
}
diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx
index 46673d20e1b7..92ed59b1d052 100644
--- a/cui/source/options/treeopt.cxx
+++ b/cui/source/options/treeopt.cxx
@@ -891,7 +891,7 @@ void OfaTreeOptionsDialog::ActivateLastSelection()
bool OfaTreeOptionsDialog::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 5cd2da24da9b..8ad859529f54 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -2323,7 +2323,7 @@ bool OfaAutoCompleteTabPage::AutoCompleteMultiListBox::PreNotify(
{
bool nHandled = MultiListBox::PreNotify( rNEvt );
- if( !nHandled && EVENT_KEYUP == rNEvt.GetType() )
+ if( !nHandled && MouseNotifyEvent::KEYUP == rNEvt.GetType() )
{
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
switch( rKeyCode.GetModifier() | rKeyCode.GetCode() )
diff --git a/cui/source/tabpages/numfmt.cxx b/cui/source/tabpages/numfmt.cxx
index 9d8682253d7f..ce26ca8fc310 100644
--- a/cui/source/tabpages/numfmt.cxx
+++ b/cui/source/tabpages/numfmt.cxx
@@ -1660,7 +1660,7 @@ void SvxNumberFormatTabPage::ChangePreviewText( sal_uInt16 nPos )
bool SvxNumberFormatTabPage::PreNotify( NotifyEvent& rNEvt )
{
- if(rNEvt.GetType()==EVENT_LOSEFOCUS)
+ if(rNEvt.GetType()==MouseNotifyEvent::LOSEFOCUS)
{
if ( rNEvt.GetWindow() == dynamic_cast< vcl::Window* >( m_pEdComment ) && !m_pEdComment->IsVisible() )
{
diff --git a/dbaccess/source/ui/app/AppDetailPageHelper.cxx b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
index 184fb484161f..559f9be2753f 100644
--- a/dbaccess/source/ui/app/AppDetailPageHelper.cxx
+++ b/dbaccess/source/ui/app/AppDetailPageHelper.cxx
@@ -142,7 +142,7 @@ namespace
bool OTablePreviewWindow::Notify( NotifyEvent& rNEvt )
{
bool nRet = Window::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_INPUTENABLE && IsInputEnabled() )
+ if ( rNEvt.GetType() == MouseNotifyEvent::INPUTENABLE && IsInputEnabled() )
PostUserEvent( LINK( this, OTablePreviewWindow, OnDisableInput) );
return nRet;
}
diff --git a/dbaccess/source/ui/app/AppView.cxx b/dbaccess/source/ui/app/AppView.cxx
index 3cc43f889c21..57371222b376 100644
--- a/dbaccess/source/ui/app/AppView.cxx
+++ b/dbaccess/source/ui/app/AppView.cxx
@@ -260,7 +260,7 @@ bool OApplicationView::PreNotify( NotifyEvent& rNEvt )
{
switch(rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
if( m_pWin && getPanel() && getPanel()->HasChildPathFocus() )
m_eChildFocus = PANELSWAP;
else if ( m_pWin && getDetailView() && getDetailView()->HasChildPathFocus() )
@@ -268,7 +268,7 @@ bool OApplicationView::PreNotify( NotifyEvent& rNEvt )
else
m_eChildFocus = NONE;
break;
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
// give the pane the chance to intercept mnemonic accelerators
diff --git a/dbaccess/source/ui/browser/brwview.cxx b/dbaccess/source/ui/browser/brwview.cxx
index 9292887c63e3..f41289e3a797 100644
--- a/dbaccess/source/ui/browser/brwview.cxx
+++ b/dbaccess/source/ui/browser/brwview.cxx
@@ -305,7 +305,7 @@ void UnoDataBrowserView::_disposing( const ::com::sun::star::lang::EventObject&
bool UnoDataBrowserView::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if(rNEvt.GetType() == EVENT_KEYINPUT)
+ if(rNEvt.GetType() == MouseNotifyEvent::KEYINPUT)
{
bool bGrabAllowed = isGrabVclControlFocusAllowed(this);
if ( bGrabAllowed )
diff --git a/dbaccess/source/ui/browser/dataview.cxx b/dbaccess/source/ui/browser/dataview.cxx
index b8509063ed43..46e87e735dfd 100644
--- a/dbaccess/source/ui/browser/dataview.cxx
+++ b/dbaccess/source/ui/browser/dataview.cxx
@@ -122,7 +122,7 @@ namespace dbaui
bool bHandled = false;
switch ( _rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = _rNEvt.GetKeyEvent();
const vcl::KeyCode& aKeyCode = pKeyEvent->GetKeyCode();
@@ -131,9 +131,9 @@ namespace dbaui
return true;
}
// NO break
- case EVENT_KEYUP:
- case EVENT_MOUSEBUTTONDOWN:
- case EVENT_MOUSEBUTTONUP:
+ case MouseNotifyEvent::KEYUP:
+ case MouseNotifyEvent::MOUSEBUTTONDOWN:
+ case MouseNotifyEvent::MOUSEBUTTONUP:
bHandled = m_rController.interceptUserInput( _rNEvt );
break;
}
diff --git a/dbaccess/source/ui/control/RelationControl.cxx b/dbaccess/source/ui/control/RelationControl.cxx
index 6fd60f549241..9c4393e63d82 100644
--- a/dbaccess/source/ui/control/RelationControl.cxx
+++ b/dbaccess/source/ui/control/RelationControl.cxx
@@ -197,9 +197,9 @@ namespace dbaui
bool ORelationControl::PreNotify(NotifyEvent& rNEvt)
{
- if (rNEvt.GetType() == EVENT_LOSEFOCUS && !HasChildPathFocus() )
+ if (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS && !HasChildPathFocus() )
PostUserEvent(LINK(this, ORelationControl, AsynchDeactivate));
- else if (rNEvt.GetType() == EVENT_GETFOCUS)
+ else if (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS)
PostUserEvent(LINK(this, ORelationControl, AsynchActivate));
return EditBrowseBox::PreNotify(rNEvt);
diff --git a/dbaccess/source/ui/control/TableGrantCtrl.cxx b/dbaccess/source/ui/control/TableGrantCtrl.cxx
index ced37d667a8c..2fab5c9627c8 100644
--- a/dbaccess/source/ui/control/TableGrantCtrl.cxx
+++ b/dbaccess/source/ui/control/TableGrantCtrl.cxx
@@ -145,14 +145,14 @@ void OTableGrantControl::Resize()
bool OTableGrantControl::PreNotify(NotifyEvent& rNEvt)
{
- if (rNEvt.GetType() == EVENT_LOSEFOCUS)
+ if (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS)
if (!HasChildPathFocus())
{
if (m_nDeactivateEvent)
Application::RemoveUserEvent(m_nDeactivateEvent);
m_nDeactivateEvent = Application::PostUserEvent(LINK(this, OTableGrantControl, AsynchDeactivate));
}
- if (rNEvt.GetType() == EVENT_GETFOCUS)
+ if (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS)
{
if (m_nDeactivateEvent)
Application::RemoveUserEvent(m_nDeactivateEvent);
diff --git a/dbaccess/source/ui/dlg/ConnectionHelper.cxx b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
index 0c404dc12b0e..4e61980ff574 100644
--- a/dbaccess/source/ui/dlg/ConnectionHelper.cxx
+++ b/dbaccess/source/ui/dlg/ConnectionHelper.cxx
@@ -560,14 +560,14 @@ namespace dbaui
{
switch (_rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
if (m_pConnectionURL->IsWindowOrChild(_rNEvt.GetWindow()) && m_bUserGrabFocus)
{ // a descendant of the URL edit field got the focus
m_pConnectionURL->SaveValueNoPrefix();
}
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
if (m_pConnectionURL->IsWindowOrChild(_rNEvt.GetWindow()) && m_bUserGrabFocus)
{ // a descendant of the URL edit field lost the focus
if (!commitURL())
diff --git a/dbaccess/source/ui/misc/WTypeSelect.cxx b/dbaccess/source/ui/misc/WTypeSelect.cxx
index 72e97daf5449..1adeadf5db6d 100644
--- a/dbaccess/source/ui/misc/WTypeSelect.cxx
+++ b/dbaccess/source/ui/misc/WTypeSelect.cxx
@@ -383,14 +383,14 @@ bool OWizTypeSelectList::PreNotify( NotifyEvent& rEvt )
bool nDone = false;
switch( rEvt.GetType() )
{
- case EVENT_MOUSEBUTTONDOWN:
+ case MouseNotifyEvent::MOUSEBUTTONDOWN:
{
const MouseEvent* pMEvt = rEvt.GetMouseEvent();
if(pMEvt->IsRight() && !pMEvt->GetModifier())
nDone = true;
}
break;
- case EVENT_COMMAND:
+ case MouseNotifyEvent::COMMAND:
{
if(!IsPrimaryKeyAllowed())
break;
diff --git a/dbaccess/source/ui/querydesign/JoinTableView.cxx b/dbaccess/source/ui/querydesign/JoinTableView.cxx
index 2944efcb97a5..c2dd15dee41a 100644
--- a/dbaccess/source/ui/querydesign/JoinTableView.cxx
+++ b/dbaccess/source/ui/querydesign/JoinTableView.cxx
@@ -1236,7 +1236,7 @@ bool OJoinTableView::PreNotify(NotifyEvent& rNEvt)
bool bHandled = false;
switch (rNEvt.GetType())
{
- case EVENT_COMMAND:
+ case MouseNotifyEvent::COMMAND:
{
const CommandEvent* pCommand = rNEvt.GetCommandEvent();
if (pCommand->GetCommand() == COMMAND_WHEEL)
@@ -1253,7 +1253,7 @@ bool OJoinTableView::PreNotify(NotifyEvent& rNEvt)
}
}
break;
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
if (m_aTableMap.empty())
// no tab wins -> no conns -> no traveling
@@ -1386,7 +1386,7 @@ bool OJoinTableView::PreNotify(NotifyEvent& rNEvt)
}
}
break;
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
{
if (m_aTableMap.empty())
// no tab wins -> no conns -> no focus change
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index e21cfe7135ce..946f03cbe320 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -2772,7 +2772,7 @@ bool OQueryDesignView::PreNotify(NotifyEvent& rNEvt)
{
switch (rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
#if OSL_DEBUG_LEVEL > 0
{
vcl::Window* pFocus = Application::GetFocusWindow();
diff --git a/dbaccess/source/ui/querydesign/TableWindow.cxx b/dbaccess/source/ui/querydesign/TableWindow.cxx
index 418d0d145f74..08155e90708c 100644
--- a/dbaccess/source/ui/querydesign/TableWindow.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindow.cxx
@@ -614,7 +614,7 @@ bool OTableWindow::PreNotify(NotifyEvent& rNEvt)
bool bHandled = false;
switch (rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
if ( getDesignView()->getController().isReadOnly() )
break;
@@ -724,7 +724,7 @@ bool OTableWindow::PreNotify(NotifyEvent& rNEvt)
}
}
break;
- case EVENT_KEYUP:
+ case MouseNotifyEvent::KEYUP:
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rCode = pKeyEvent->GetKeyCode();
diff --git a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
index 636dc9a26d7e..35eac4cbace4 100644
--- a/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowListBox.cxx
@@ -132,7 +132,7 @@ bool OTableWindowListBox::PreNotify(NotifyEvent& rNEvt)
bool bHandled = false;
switch (rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rCode = pKeyEvent->GetKeyCode();
diff --git a/dbaccess/source/ui/querydesign/limitboxcontroller.cxx b/dbaccess/source/ui/querydesign/limitboxcontroller.cxx
index dd3e1315b107..5b767649471c 100644
--- a/dbaccess/source/ui/querydesign/limitboxcontroller.cxx
+++ b/dbaccess/source/ui/querydesign/limitboxcontroller.cxx
@@ -57,7 +57,7 @@ bool LimitBoxImpl::Notify( NotifyEvent& rNEvt )
bool nHandled = false;
switch ( rNEvt.GetType() )
{
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
{
nHandled = LimitBox::Notify( rNEvt );
uno::Sequence< beans::PropertyValue > aArgs( 1 );
@@ -66,7 +66,7 @@ bool LimitBoxImpl::Notify( NotifyEvent& rNEvt )
m_pControl->dispatchCommand( aArgs );
break;
}
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
switch ( nCode )
diff --git a/dbaccess/source/ui/querydesign/querycontainerwindow.cxx b/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
index 5465148be499..7afd1c9ec663 100644
--- a/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
+++ b/dbaccess/source/ui/querydesign/querycontainerwindow.cxx
@@ -160,7 +160,7 @@ namespace dbaui
bool bHandled = false;
switch (rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
if ( m_pViewSwitch )
{
OJoinController& rController = m_pViewSwitch->getDesignView()->getController();
diff --git a/dbaccess/source/ui/relationdesign/RelationDesignView.cxx b/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
index 0305b4603736..a27f4a5b2eb6 100644
--- a/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
+++ b/dbaccess/source/ui/relationdesign/RelationDesignView.cxx
@@ -71,7 +71,7 @@ void ORelationDesignView::initialize()
bool ORelationDesignView::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if(rNEvt.GetType() == EVENT_GETFOCUS)
+ if(rNEvt.GetType() == MouseNotifyEvent::GETFOCUS)
{
if(!m_pTableView->HasChildPathFocus())
{
diff --git a/dbaccess/source/ui/tabledesign/TEditControl.cxx b/dbaccess/source/ui/tabledesign/TEditControl.cxx
index 2b66dc046472..a9af7d9d0e6d 100644
--- a/dbaccess/source/ui/tabledesign/TEditControl.cxx
+++ b/dbaccess/source/ui/tabledesign/TEditControl.cxx
@@ -1684,7 +1684,7 @@ void OTableEditorCtrl::DeactivateCell(bool bUpdate)
bool OTableEditorCtrl::PreNotify( NotifyEvent& rNEvt )
{
- if (rNEvt.GetType() == EVENT_GETFOCUS)
+ if (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS)
{
if( pHelpTextCell && pHelpTextCell->HasChildPathFocus() )
m_eChildFocus = HELPTEXT;
diff --git a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
index 5a69fc0b7ead..a5f2010fb15d 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignHelpBar.cxx
@@ -64,7 +64,7 @@ void OTableDesignHelpBar::Resize()
bool OTableDesignHelpBar::PreNotify( NotifyEvent& rNEvt )
{
- if (rNEvt.GetType() == EVENT_LOSEFOCUS)
+ if (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS)
SetHelpText(OUString());
return TabPage::PreNotify(rNEvt);
}
diff --git a/dbaccess/source/ui/tabledesign/TableDesignView.cxx b/dbaccess/source/ui/tabledesign/TableDesignView.cxx
index b1743c5d35cd..16bc2dfc9cce 100644
--- a/dbaccess/source/ui/tabledesign/TableDesignView.cxx
+++ b/dbaccess/source/ui/tabledesign/TableDesignView.cxx
@@ -224,7 +224,7 @@ bool OTableDesignView::PreNotify( NotifyEvent& rNEvt )
bool bHandled = false;
switch(rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
if( GetDescWin() && GetDescWin()->HasChildPathFocus() )
m_eChildFocus = DESCRIPTION;
else if ( GetEditorCtrl() && GetEditorCtrl()->HasChildPathFocus() )
diff --git a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
index eef570c905d2..fecf0f348b22 100644
--- a/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
+++ b/dbaccess/source/ui/tabledesign/TableFieldDescWin.cxx
@@ -269,7 +269,7 @@ bool OTableFieldDescWin::PreNotify( NotifyEvent& rNEvt )
bool bHandled = false;
switch(rNEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
if( getGenPage() && getGenPage()->HasChildPathFocus() )
m_eChildFocus = DESCRIPTION;
else
diff --git a/desktop/source/deployment/gui/dp_gui_dialog2.cxx b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
index 63fe3828da47..c4bb27407089 100644
--- a/desktop/source/deployment/gui/dp_gui_dialog2.cxx
+++ b/desktop/source/deployment/gui/dp_gui_dialog2.cxx
@@ -422,7 +422,7 @@ bool ExtBoxWithBtns_Impl::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -1109,7 +1109,7 @@ bool ExtMgrDialog::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
index ab5e0494289f..ce629ed6e2e8 100644
--- a/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
+++ b/desktop/source/deployment/gui/dp_gui_extlistbox.cxx
@@ -879,7 +879,7 @@ bool ExtensionBox_Impl::Notify( NotifyEvent& rNEvt )
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -891,7 +891,7 @@ bool ExtensionBox_Impl::Notify( NotifyEvent& rNEvt )
bHandled = HandleCursorKey( nKeyCode );
}
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
if ( m_bHasScrollBar &&
( rNEvt.GetCommandEvent()->GetCommand() == COMMAND_WHEEL ) )
diff --git a/extensions/source/bibliography/bibcont.cxx b/extensions/source/bibliography/bibcont.cxx
index c7787c49d04e..488a24f4e1ca 100644
--- a/extensions/source/bibliography/bibcont.cxx
+++ b/extensions/source/bibliography/bibcont.cxx
@@ -212,7 +212,7 @@ void BibBookContainer::GetFocus()
bool BibBookContainer::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if( EVENT_KEYINPUT == rNEvt.GetType() )
+ if( MouseNotifyEvent::KEYINPUT == rNEvt.GetType() )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/extensions/source/bibliography/toolbar.cxx b/extensions/source/bibliography/toolbar.cxx
index d4f433ec763d..86ef53333d13 100644
--- a/extensions/source/bibliography/toolbar.cxx
+++ b/extensions/source/bibliography/toolbar.cxx
@@ -426,8 +426,8 @@ bool BibToolBar::PreNotify( NotifyEvent& rNEvt )
{
bool nResult = true;
- sal_uInt16 nSwitch=rNEvt.GetType();
- if(aEdQuery.HasFocus() && nSwitch==EVENT_KEYINPUT)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if(aEdQuery.HasFocus() && nSwitch==MouseNotifyEvent::KEYINPUT)
{
const vcl::KeyCode& aKeyCode=rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey = aKeyCode.GetCode();
diff --git a/extensions/source/propctrlr/browserlistbox.cxx b/extensions/source/propctrlr/browserlistbox.cxx
index 66664193ad9b..c43a058f4fb8 100644
--- a/extensions/source/propctrlr/browserlistbox.cxx
+++ b/extensions/source/propctrlr/browserlistbox.cxx
@@ -1205,7 +1205,7 @@ namespace pcr
{
switch ( _rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = _rNEvt.GetKeyEvent();
if ( ( pKeyEvent->GetKeyCode().GetModifier() != 0 )
@@ -1263,7 +1263,7 @@ namespace pcr
{
switch ( _rNEvt.GetType() )
{
- case EVENT_COMMAND:
+ case MouseNotifyEvent::COMMAND:
{
const CommandEvent* pCommand = _rNEvt.GetCommandEvent();
if ( ( COMMAND_WHEEL == pCommand->GetCommand() )
diff --git a/extensions/source/propctrlr/browserview.cxx b/extensions/source/propctrlr/browserview.cxx
index f56532cab6d0..4179cbe8e3ed 100644
--- a/extensions/source/propctrlr/browserview.cxx
+++ b/extensions/source/propctrlr/browserview.cxx
@@ -83,7 +83,7 @@ namespace pcr
bool OPropertyBrowserView::Notify( NotifyEvent& _rNEvt )
{
- if ( EVENT_KEYINPUT == _rNEvt.GetType() )
+ if ( MouseNotifyEvent::KEYINPUT == _rNEvt.GetType() )
{
sal_uInt16 nKey = _rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
diff --git a/extensions/source/propctrlr/commoncontrol.cxx b/extensions/source/propctrlr/commoncontrol.cxx
index 0e95203be50a..ac33ace00daa 100644
--- a/extensions/source/propctrlr/commoncontrol.cxx
+++ b/extensions/source/propctrlr/commoncontrol.cxx
@@ -128,7 +128,7 @@ namespace pcr
bool ControlHelper::handlePreNotify(NotifyEvent& rNEvt)
{
- if (EVENT_KEYINPUT == rNEvt.GetType())
+ if (MouseNotifyEvent::KEYINPUT == rNEvt.GetType())
{
const vcl::KeyCode& aKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey = aKeyCode.GetCode();
diff --git a/extensions/source/propctrlr/standardcontrol.cxx b/extensions/source/propctrlr/standardcontrol.cxx
index 60d64a91e43a..4e1c60037db1 100644
--- a/extensions/source/propctrlr/standardcontrol.cxx
+++ b/extensions/source/propctrlr/standardcontrol.cxx
@@ -993,8 +993,8 @@ namespace pcr
{
bool nResult = true;
- sal_uInt16 nSwitch = _rNEvt.GetType();
- if (EVENT_KEYINPUT == nSwitch)
+ MouseNotifyEvent nSwitch = _rNEvt.GetType();
+ if (MouseNotifyEvent::KEYINPUT == nSwitch)
{
const vcl::KeyCode& aKeyCode = _rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey = aKeyCode.GetCode();
@@ -1099,7 +1099,7 @@ namespace pcr
{
bool nResult = true;
- if (rNEvt.GetType() == EVENT_KEYINPUT)
+ if (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT)
{
const vcl::KeyCode& aKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey = aKeyCode.GetCode();
diff --git a/extensions/source/propctrlr/standardcontrol.hxx b/extensions/source/propctrlr/standardcontrol.hxx
index fdfb1dc638d1..a78b43ed0359 100644
--- a/extensions/source/propctrlr/standardcontrol.hxx
+++ b/extensions/source/propctrlr/standardcontrol.hxx
@@ -73,7 +73,7 @@ namespace pcr
template< class LISTBOX_WINDOW >
bool ListLikeControlWithModifyHandler< LISTBOX_WINDOW >::PreNotify( NotifyEvent& _rNEvt )
{
- if ( _rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( _rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const ::KeyEvent* pKeyEvent = _rNEvt.GetKeyEvent();
if ( ( pKeyEvent->GetKeyCode().GetModifier() == 0 )
diff --git a/extensions/source/propctrlr/usercontrol.cxx b/extensions/source/propctrlr/usercontrol.cxx
index f26035c1d1c6..783e43c84a49 100644
--- a/extensions/source/propctrlr/usercontrol.cxx
+++ b/extensions/source/propctrlr/usercontrol.cxx
@@ -48,7 +48,7 @@ namespace pcr
bool NumberFormatSampleField::PreNotify( NotifyEvent& rNEvt )
{
// want to handle two keys myself : Del/Backspace should empty the window (setting my prop to "standard" this way)
- if (EVENT_KEYINPUT == rNEvt.GetType())
+ if (MouseNotifyEvent::KEYINPUT == rNEvt.GetType())
{
sal_uInt16 nKey = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
diff --git a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
index fc0da394f46f..02143c4abeb3 100644
--- a/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
+++ b/filter/source/xsltdialog/xmlfiltersettingsdialog.cxx
@@ -1004,7 +1004,7 @@ bool XMLFilterSettingsDialog::Notify( NotifyEvent& rNEvt )
bool nRet = ModelessDialog::Notify( rNEvt );
if ( !nRet )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -1408,7 +1408,7 @@ bool SvxPathControl::Notify(NotifyEvent& rNEvt)
{
bool nRet = Window::Notify(rNEvt);
- if ( m_pFocusCtrl && rNEvt.GetWindow() != m_pFocusCtrl && rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( m_pFocusCtrl && rNEvt.GetWindow() != m_pFocusCtrl && rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
m_pFocusCtrl->GrabFocus();
return nRet;
diff --git a/forms/source/richtext/richtextvclcontrol.cxx b/forms/source/richtext/richtextvclcontrol.cxx
index 21c8a51ba81c..fe7ffe6f70c7 100644
--- a/forms/source/richtext/richtextvclcontrol.cxx
+++ b/forms/source/richtext/richtextvclcontrol.cxx
@@ -189,7 +189,7 @@ namespace frm
{
if ( IsWindowOrChild( _rNEvt.GetWindow() ) )
{
- if ( EVENT_KEYINPUT == _rNEvt.GetType() )
+ if ( MouseNotifyEvent::KEYINPUT == _rNEvt.GetType() )
{
const ::KeyEvent* pKeyEvent = _rNEvt.GetKeyEvent();
@@ -281,7 +281,7 @@ namespace frm
bool RichTextControl::Notify( NotifyEvent& _rNEvt )
{
bool nDone = false;
- if ( _rNEvt.GetType() == EVENT_COMMAND )
+ if ( _rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent& rEvent = *_rNEvt.GetCommandEvent();
nDone = m_pImpl->HandleCommand( rEvent );
diff --git a/formula/source/ui/dlg/formula.cxx b/formula/source/ui/dlg/formula.cxx
index 5573f72f152f..b17da4f5d3d2 100644
--- a/formula/source/ui/dlg/formula.cxx
+++ b/formula/source/ui/dlg/formula.cxx
@@ -388,8 +388,8 @@ void FormulaDlg_Impl::StoreFormEditData(FormEditData* pData)
void FormulaDlg_Impl::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nSwitch=rNEvt.GetType();
- if(nSwitch==EVENT_GETFOCUS && !bIsShutDown)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if(nSwitch==MouseNotifyEvent::GETFOCUS && !bIsShutDown)
{
vcl::Window* pWin=rNEvt.GetWindow();
if(pWin!=NULL)
diff --git a/formula/source/ui/dlg/funcpage.cxx b/formula/source/ui/dlg/funcpage.cxx
index e99674f50623..e44455e41424 100644
--- a/formula/source/ui/dlg/funcpage.cxx
+++ b/formula/source/ui/dlg/funcpage.cxx
@@ -49,8 +49,8 @@ bool FormulaListBox::PreNotify( NotifyEvent& rNEvt )
bool nResult = ListBox::PreNotify(rNEvt);
- sal_uInt16 nSwitch=aNotifyEvt.GetType();
- if(nSwitch==EVENT_KEYINPUT)
+ MouseNotifyEvent nSwitch=aNotifyEvt.GetType();
+ if(nSwitch==MouseNotifyEvent::KEYINPUT)
{
KeyInput(*aNotifyEvt.GetKeyEvent());
}
diff --git a/formula/source/ui/dlg/funcutl.cxx b/formula/source/ui/dlg/funcutl.cxx
index c02ed91cc37f..65fd1f4d4e2b 100644
--- a/formula/source/ui/dlg/funcutl.cxx
+++ b/formula/source/ui/dlg/funcutl.cxx
@@ -398,8 +398,8 @@ bool EditBox::PreNotify( NotifyEvent& rNEvt )
if(pMEdit==NULL) return nResult;
- sal_uInt16 nSwitch=rNEvt.GetType();
- if(nSwitch==EVENT_KEYINPUT)// || nSwitch==EVENT_KEYUP)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if(nSwitch==MouseNotifyEvent::KEYINPUT)// || nSwitch==MouseNotifyEvent::KEYUP)
{
const vcl::KeyCode& aKeyCode=rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey=aKeyCode.GetCode();
@@ -418,7 +418,7 @@ bool EditBox::PreNotify( NotifyEvent& rNEvt )
{
nResult=Control::PreNotify(rNEvt);
- if(nSwitch==EVENT_MOUSEBUTTONDOWN || nSwitch==EVENT_MOUSEBUTTONUP)
+ if(nSwitch==MouseNotifyEvent::MOUSEBUTTONDOWN || nSwitch==MouseNotifyEvent::MOUSEBUTTONUP)
{
bMouseFlag=true;
Application::PostUserEvent( LINK( this, EditBox, ChangedHdl ) );
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index 81ce17e4532d..41c76d30e053 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -1593,10 +1593,10 @@ bool SvtFileDialog::Notify( NotifyEvent& rNEvt )
*/
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
bool nRet = false;
- if ( EVENT_KEYINPUT == nType && rNEvt.GetKeyEvent() )
+ if ( MouseNotifyEvent::KEYINPUT == nType && rNEvt.GetKeyEvent() )
{
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nCode = rKeyCode.GetCode();
diff --git a/framework/source/uielement/comboboxtoolbarcontroller.cxx b/framework/source/uielement/comboboxtoolbarcontroller.cxx
index 6a685cfb71a7..2f3cefb4f4d0 100644
--- a/framework/source/uielement/comboboxtoolbarcontroller.cxx
+++ b/framework/source/uielement/comboboxtoolbarcontroller.cxx
@@ -222,7 +222,7 @@ bool ComboboxToolbarController::PreNotify( NotifyEvent& rNEvt )
{
switch ( rNEvt.GetType() )
{
- case EVENT_KEYINPUT :
+ case MouseNotifyEvent::KEYINPUT :
{
const ::KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKeyEvent->GetKeyCode();
@@ -235,10 +235,10 @@ bool ComboboxToolbarController::PreNotify( NotifyEvent& rNEvt )
}
}
break;
- case EVENT_GETFOCUS :
+ case MouseNotifyEvent::GETFOCUS :
notifyFocusGet();
break;
- case EVENT_LOSEFOCUS :
+ case MouseNotifyEvent::LOSEFOCUS :
notifyFocusLost();
break;
default :
diff --git a/framework/source/uielement/edittoolbarcontroller.cxx b/framework/source/uielement/edittoolbarcontroller.cxx
index c38a2a5526b6..67cdcb1e2e3d 100644
--- a/framework/source/uielement/edittoolbarcontroller.cxx
+++ b/framework/source/uielement/edittoolbarcontroller.cxx
@@ -186,7 +186,7 @@ void EditToolbarController::LoseFocus()
bool EditToolbarController::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const ::KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKeyEvent->GetKeyCode();
diff --git a/framework/source/uielement/spinfieldtoolbarcontroller.cxx b/framework/source/uielement/spinfieldtoolbarcontroller.cxx
index 83557df32f01..efe6a711877f 100644
--- a/framework/source/uielement/spinfieldtoolbarcontroller.cxx
+++ b/framework/source/uielement/spinfieldtoolbarcontroller.cxx
@@ -308,7 +308,7 @@ void SpinfieldToolbarController::DataChanged( const DataChangedEvent& /*rDCEvt*/
bool SpinfieldToolbarController::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const ::KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKeyEvent->GetKeyCode();
diff --git a/include/vcl/event.hxx b/include/vcl/event.hxx
index 14181cc4e2f9..a73c57138b5e 100644
--- a/include/vcl/event.hxx
+++ b/include/vcl/event.hxx
@@ -389,38 +389,41 @@ inline TrackingEvent::TrackingEvent( const MouseEvent& rMEvt,
// - NotifyEvent -
-
-#define EVENT_MOUSEBUTTONDOWN 1
-#define EVENT_MOUSEBUTTONUP 2
-#define EVENT_MOUSEMOVE 3
-#define EVENT_KEYINPUT 4
-#define EVENT_KEYUP 5
-#define EVENT_GETFOCUS 6
-#define EVENT_LOSEFOCUS 7
-#define EVENT_COMMAND 8
-#define EVENT_DESTROY 9
-#define EVENT_INPUTENABLE 10
-#define EVENT_INPUTDISABLE 11
-#define EVENT_EXECUTEDIALOG 100
-#define EVENT_ENDEXECUTEDIALOG 101
+enum class MouseNotifyEvent
+{
+ NONE = 0,
+ MOUSEBUTTONDOWN = 1,
+ MOUSEBUTTONUP = 2,
+ MOUSEMOVE = 3,
+ KEYINPUT = 4,
+ KEYUP = 5,
+ GETFOCUS = 6,
+ LOSEFOCUS = 7,
+ COMMAND = 8,
+ DESTROY = 9,
+ INPUTENABLE = 10,
+ INPUTDISABLE = 11,
+ EXECUTEDIALOG = 100,
+ ENDEXECUTEDIALOG = 101
+};
class VCL_DLLPUBLIC NotifyEvent
{
private:
vcl::Window* mpWindow;
void* mpData;
- sal_uInt16 mnType;
+ MouseNotifyEvent mnEventType;
long mnRetValue;
public:
NotifyEvent();
- NotifyEvent( sal_uInt16 nType,
+ NotifyEvent( MouseNotifyEvent nEventType,
vcl::Window* pWindow,
const void* pEvent = NULL,
long nRet = 0 );
- sal_uInt16 GetType() const { return mnType; }
- vcl::Window* GetWindow() const { return mpWindow; }
+ MouseNotifyEvent GetType() const { return mnEventType; }
+ vcl::Window* GetWindow() const { return mpWindow; }
void* GetData() const { return mpData; }
void SetReturnValue( long nRet ) { mnRetValue = nRet; }
@@ -435,22 +438,22 @@ inline NotifyEvent::NotifyEvent()
{
mpWindow = NULL;
mpData = NULL;
- mnType = 0;
+ mnEventType = MouseNotifyEvent::NONE;
mnRetValue = 0;
}
-inline NotifyEvent::NotifyEvent( sal_uInt16 nType, vcl::Window* pWindow,
+inline NotifyEvent::NotifyEvent( MouseNotifyEvent nEventType, vcl::Window* pWindow,
const void* pEvent, long nRet )
{
mpWindow = pWindow;
mpData = (void*)pEvent;
- mnType = nType;
+ mnEventType = nEventType;
mnRetValue = nRet;
}
inline const KeyEvent* NotifyEvent::GetKeyEvent() const
{
- if ( (mnType == EVENT_KEYINPUT) || (mnType == EVENT_KEYUP) )
+ if ( (mnEventType == MouseNotifyEvent::KEYINPUT) || (mnEventType == MouseNotifyEvent::KEYUP) )
return (const KeyEvent*)mpData;
else
return NULL;
@@ -458,7 +461,7 @@ inline const KeyEvent* NotifyEvent::GetKeyEvent() const
inline const MouseEvent* NotifyEvent::GetMouseEvent() const
{
- if ( (mnType >= EVENT_MOUSEBUTTONDOWN) && (mnType <= EVENT_MOUSEMOVE) )
+ if ( (mnEventType >= MouseNotifyEvent::MOUSEBUTTONDOWN) && (mnEventType <= MouseNotifyEvent::MOUSEMOVE) )
return (const MouseEvent*)mpData;
else
return NULL;
@@ -466,7 +469,7 @@ inline const MouseEvent* NotifyEvent::GetMouseEvent() const
inline const CommandEvent* NotifyEvent::GetCommandEvent() const
{
- if ( mnType == EVENT_COMMAND )
+ if ( mnEventType == MouseNotifyEvent::COMMAND )
return (const CommandEvent*)mpData;
else
return NULL;
diff --git a/reportdesign/source/ui/dlg/AddField.cxx b/reportdesign/source/ui/dlg/AddField.cxx
index c572af9c6a90..d1e646097710 100644
--- a/reportdesign/source/ui/dlg/AddField.cxx
+++ b/reportdesign/source/ui/dlg/AddField.cxx
@@ -241,7 +241,7 @@ uno::Sequence< beans::PropertyValue > OAddFieldWindow::getSelectedFieldDescripto
bool OAddFieldWindow::PreNotify( NotifyEvent& _rNEvt )
{
- if ( EVENT_KEYINPUT == _rNEvt.GetType() )
+ if ( MouseNotifyEvent::KEYINPUT == _rNEvt.GetType() )
{
const vcl::KeyCode& rKeyCode = _rNEvt.GetKeyEvent()->GetKeyCode();
if ( ( 0 == rKeyCode.GetModifier() ) && ( KEY_RETURN == rKeyCode.GetCode() ) )
diff --git a/reportdesign/source/ui/dlg/CondFormat.cxx b/reportdesign/source/ui/dlg/CondFormat.cxx
index fbdd9fc4e157..a4d8c031470a 100644
--- a/reportdesign/source/ui/dlg/CondFormat.cxx
+++ b/reportdesign/source/ui/dlg/CondFormat.cxx
@@ -472,7 +472,7 @@ namespace rptui
{
switch ( _rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent( _rNEvt.GetKeyEvent() );
const vcl::KeyCode& rKeyCode = pKeyEvent->GetKeyCode();
@@ -491,7 +491,7 @@ namespace rptui
}
}
break;
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
{
if ( m_bDeletingCondition )
break;
diff --git a/reportdesign/source/ui/report/DesignView.cxx b/reportdesign/source/ui/report/DesignView.cxx
index b9df2babf467..7aecedeae1ba 100644
--- a/reportdesign/source/ui/report/DesignView.cxx
+++ b/reportdesign/source/ui/report/DesignView.cxx
@@ -181,7 +181,7 @@ bool ODesignView::PreNotify( NotifyEvent& rNEvt )
bool nRet = ODataView::PreNotify(rNEvt); // 1 := has to be handled here
switch(rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if ( (m_pPropWin && m_pPropWin->HasChildPathFocus()) )
return false;
if ( (m_pAddField && m_pAddField->HasChildPathFocus()) )
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 7a1a84fb711b..6e4a2389bb3e 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -2452,7 +2452,7 @@ bool ScPosWnd::Notify( NotifyEvent& rNEvt )
switch (rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
@@ -2478,14 +2478,14 @@ bool ScPosWnd::Notify( NotifyEvent& rNEvt )
}
}
break;
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
{
// Select the whole text upon focus.
OUString aStr = GetText();
SetSelection(Selection(0, aStr.getLength()));
}
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
HideTip();
bHandled = false;
break;
diff --git a/sc/source/ui/cctrl/checklistmenu.cxx b/sc/source/ui/cctrl/checklistmenu.cxx
index 9fbcd2c65e52..cbf834e885fb 100644
--- a/sc/source/ui/cctrl/checklistmenu.cxx
+++ b/sc/source/ui/cctrl/checklistmenu.cxx
@@ -1171,7 +1171,7 @@ bool ScCheckListMenuWindow::Notify(NotifyEvent& rNEvt)
{
switch (rNEvt.GetType())
{
- case EVENT_KEYUP:
+ case MouseNotifyEvent::KEYUP:
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
const vcl::KeyCode& rCode = pKeyEvent->GetKeyCode();
diff --git a/sc/source/ui/condformat/condformatdlgentry.cxx b/sc/source/ui/condformat/condformatdlgentry.cxx
index 10fd33fbbd8b..81d907696561 100644
--- a/sc/source/ui/condformat/condformatdlgentry.cxx
+++ b/sc/source/ui/condformat/condformatdlgentry.cxx
@@ -65,7 +65,7 @@ ScCondFrmtEntry::~ScCondFrmtEntry()
bool ScCondFrmtEntry::Notify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
ImplCallEventListenersAndHandler( VCLEVENT_WINDOW_MOUSEBUTTONDOWN, maClickHdl, this );
}
diff --git a/sc/source/ui/miscdlgs/acredlin.cxx b/sc/source/ui/miscdlgs/acredlin.cxx
index 8614e813bec7..a511a1444597 100644
--- a/sc/source/ui/miscdlgs/acredlin.cxx
+++ b/sc/source/ui/miscdlgs/acredlin.cxx
@@ -747,7 +747,7 @@ SvTreeListEntry* ScAcceptChgDlg::InsertChangeActionContent(const ScChangeActionC
bool ScAcceptChgDlg::PreNotify( NotifyEvent& rNEvt )
{
- if(rNEvt.GetType()==EVENT_GETFOCUS && bNeedsUpdate)
+ if(rNEvt.GetType()==MouseNotifyEvent::GETFOCUS && bNeedsUpdate)
{
ClearView();
UpdateView();
diff --git a/sc/source/ui/miscdlgs/anyrefdg.cxx b/sc/source/ui/miscdlgs/anyrefdg.cxx
index 32448aa8c707..cb5ea7c6bf21 100644
--- a/sc/source/ui/miscdlgs/anyrefdg.cxx
+++ b/sc/source/ui/miscdlgs/anyrefdg.cxx
@@ -937,8 +937,8 @@ void ScRefHandler::preNotify(const NotifyEvent& rNEvt, const bool bBindRef)
{
if( bBindRef || m_bInRefMode )
{
- sal_uInt16 nSwitch=rNEvt.GetType();
- if(nSwitch==EVENT_GETFOCUS)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if(nSwitch==MouseNotifyEvent::GETFOCUS)
{
pActiveWin=rNEvt.GetWindow();
}
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx
index b3a1f190f502..1f5d7fa76f45 100644
--- a/sc/source/ui/navipi/navipi.cxx
+++ b/sc/source/ui/navipi/navipi.cxx
@@ -95,8 +95,8 @@ bool ColumnEdit::Notify( NotifyEvent& rNEvt )
{
bool nHandled = SpinField::Notify( rNEvt );
- sal_uInt16 nType = rNEvt.GetType();
- if ( nType == EVENT_KEYINPUT )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( nType == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aCode = pKEvt->GetKeyCode();
@@ -115,8 +115,8 @@ bool ColumnEdit::Notify( NotifyEvent& rNEvt )
}
}
}
- else if ( nType == EVENT_LOSEFOCUS ) // LoseFocus wird bei VCL nicht gerufen
- EvalText(); // nCol setzen
+ else if ( nType == MouseNotifyEvent::LOSEFOCUS ) // LoseFocus not called at VCL
+ EvalText(); // nCol set
return nHandled;
}
@@ -267,7 +267,7 @@ bool RowEdit::Notify( NotifyEvent& rNEvt )
{
bool nHandled = NumericField::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aCode = pKEvt->GetKeyCode();
diff --git a/sc/source/ui/navipi/scenwnd.cxx b/sc/source/ui/navipi/scenwnd.cxx
index d72a7456c21d..96b37d81602d 100644
--- a/sc/source/ui/navipi/scenwnd.cxx
+++ b/sc/source/ui/navipi/scenwnd.cxx
@@ -111,7 +111,7 @@ bool ScScenarioListBox::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
vcl::KeyCode aCode = rNEvt.GetKeyEvent()->GetKeyCode();
switch( aCode.GetCode() )
@@ -126,7 +126,7 @@ bool ScScenarioListBox::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if ( rNEvt.GetType() == EVENT_COMMAND && GetSelectEntryCount() )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND && GetSelectEntryCount() )
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
if ( pCEvt && pCEvt->GetCommand() == COMMAND_CONTEXTMENU )
diff --git a/sc/source/ui/pagedlg/tphfedit.cxx b/sc/source/ui/pagedlg/tphfedit.cxx
index 5b79c98535d6..1fca515a8c79 100644
--- a/sc/source/ui/pagedlg/tphfedit.cxx
+++ b/sc/source/ui/pagedlg/tphfedit.cxx
@@ -396,8 +396,8 @@ void ScExtIButton::StartPopup()
bool ScExtIButton::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nSwitch=rNEvt.GetType();
- if(nSwitch==EVENT_MOUSEBUTTONUP)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if(nSwitch==MouseNotifyEvent::MOUSEBUTTONUP)
{
MouseButtonUp(*rNEvt.GetMouseEvent());
}
diff --git a/sc/source/ui/view/gridwin.cxx b/sc/source/ui/view/gridwin.cxx
index 7b27f0caae98..10442a79f79b 100644
--- a/sc/source/ui/view/gridwin.cxx
+++ b/sc/source/ui/view/gridwin.cxx
@@ -277,7 +277,7 @@ void ScFilterListBox::LoseFocus()
bool ScFilterListBox::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
vcl::KeyCode aCode = aKeyEvt.GetKeyCode();
@@ -2653,8 +2653,8 @@ static void lcl_InitMouseEvent( ::com::sun::star::awt::MouseEvent& rEvent, const
bool ScGridWindow::PreNotify( NotifyEvent& rNEvt )
{
bool bDone = false;
- sal_uInt16 nType = rNEvt.GetType();
- if ( nType == EVENT_MOUSEBUTTONUP || nType == EVENT_MOUSEBUTTONDOWN )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( nType == MouseNotifyEvent::MOUSEBUTTONUP || nType == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
vcl::Window* pWindow = rNEvt.GetWindow();
if (pWindow == this && pViewData)
@@ -2672,7 +2672,7 @@ bool ScGridWindow::PreNotify( NotifyEvent& rNEvt )
lcl_InitMouseEvent( aEvent, *rNEvt.GetMouseEvent() );
if ( rNEvt.GetWindow() )
aEvent.Source = rNEvt.GetWindow()->GetComponentInterface();
- if ( nType == EVENT_MOUSEBUTTONDOWN)
+ if ( nType == MouseNotifyEvent::MOUSEBUTTONDOWN)
bDone = pImp->MousePressed( aEvent );
else
bDone = pImp->MouseReleased( aEvent );
@@ -2683,7 +2683,7 @@ bool ScGridWindow::PreNotify( NotifyEvent& rNEvt )
}
if (bDone) // event consumed by a listener
{
- if ( nType == EVENT_MOUSEBUTTONDOWN )
+ if ( nType == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseEvent* pMouseEvent = rNEvt.GetMouseEvent();
if ( pMouseEvent->IsRight() && pMouseEvent->GetClicks() == 1 )
diff --git a/sd/source/ui/animations/CustomAnimationDialog.cxx b/sd/source/ui/animations/CustomAnimationDialog.cxx
index 2e0272fb3e9c..97f9559bf5c6 100644
--- a/sd/source/ui/animations/CustomAnimationDialog.cxx
+++ b/sd/source/ui/animations/CustomAnimationDialog.cxx
@@ -370,8 +370,8 @@ bool DropdownMenuBox::PreNotify( NotifyEvent& rNEvt )
{
bool nResult = true;
- sal_uInt16 nSwitch=rNEvt.GetType();
- if (nSwitch==EVENT_KEYINPUT)
+ MouseNotifyEvent nSwitch=rNEvt.GetType();
+ if (nSwitch==MouseNotifyEvent::KEYINPUT)
{
const vcl::KeyCode& aKeyCode=rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey=aKeyCode.GetCode();
diff --git a/sd/source/ui/dlg/RemoteDialogClientBox.cxx b/sd/source/ui/dlg/RemoteDialogClientBox.cxx
index cd99a249a879..ac27e7717dd8 100644
--- a/sd/source/ui/dlg/RemoteDialogClientBox.cxx
+++ b/sd/source/ui/dlg/RemoteDialogClientBox.cxx
@@ -595,7 +595,7 @@ bool ClientBox::Notify( NotifyEvent& rNEvt )
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -607,7 +607,7 @@ bool ClientBox::Notify( NotifyEvent& rNEvt )
bHandled = HandleCursorKey( nKeyCode );
}
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
if ( m_bHasScrollBar &&
( rNEvt.GetCommandEvent()->GetCommand() == COMMAND_WHEEL ) )
diff --git a/sd/source/ui/dlg/docprev.cxx b/sd/source/ui/dlg/docprev.cxx
index 32516f927aff..ec0b4e6b893f 100644
--- a/sd/source/ui/dlg/docprev.cxx
+++ b/sd/source/ui/dlg/docprev.cxx
@@ -189,7 +189,7 @@ void SdDocPreviewWin::startPreview()
bool SdDocPreviewWin::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
if ( pMEvt->IsLeft() )
diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx
index da3d6edbb35a..736de7679af5 100644
--- a/sd/source/ui/view/viewshel.cxx
+++ b/sd/source/ui/view/viewshel.cxx
@@ -597,7 +597,7 @@ bool ViewShell::Notify(NotifyEvent& rNEvt, ::sd::Window* pWin)
{
// handle scroll commands when they arrived at child windows
bool nRet = false;
- if( rNEvt.GetType() == EVENT_COMMAND )
+ if( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
// note: dynamic_cast is not possible as GetData() returns a void*
CommandEvent* pCmdEvent = reinterpret_cast< CommandEvent* >(rNEvt.GetData());
diff --git a/sfx2/source/appl/newhelp.cxx b/sfx2/source/appl/newhelp.cxx
index baec605a2cad..ae3a2cdccaac 100644
--- a/sfx2/source/appl/newhelp.cxx
+++ b/sfx2/source/appl/newhelp.cxx
@@ -397,7 +397,7 @@ void ContentListBox_Impl::RequestingChildren( SvTreeListEntry* pParent )
bool ContentListBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT &&
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT &&
KEY_RETURN == rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
{
GetDoubleClickHdl().Call( NULL );
@@ -491,7 +491,7 @@ void IndexBox_Impl::UserDraw( const UserDrawEvent& rUDEvt )
bool IndexBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT &&
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT &&
KEY_RETURN == rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
{
GetDoubleClickHdl().Call( NULL );
@@ -850,7 +850,7 @@ bool SearchBox_Impl::PreNotify( NotifyEvent& rNEvt )
bool bHandled = false;
if ( !IsInDropDown() &&
rNEvt.GetWindow() == GetSubEdit() &&
- rNEvt.GetType() == EVENT_KEYINPUT &&
+ rNEvt.GetType() == MouseNotifyEvent::KEYINPUT &&
KEY_RETURN == rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
{
aSearchLink.Call( NULL );
@@ -884,7 +884,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSearchResultsBox(vcl::
bool SearchResultsBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT &&
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT &&
KEY_RETURN == rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
{
GetDoubleClickHdl().Call( NULL );
@@ -1208,8 +1208,8 @@ void BookmarksBox_Impl::DoAction( sal_uInt16 nAction )
bool BookmarksBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool nRet = false;
- sal_uInt16 nType = rNEvt.GetType();
- if ( EVENT_KEYINPUT == nType )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( MouseNotifyEvent::KEYINPUT == nType )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
if ( KEY_DELETE == nCode && GetEntryCount() > 0 )
@@ -1223,7 +1223,7 @@ bool BookmarksBox_Impl::Notify( NotifyEvent& rNEvt )
nRet = true;
}
}
- else if ( EVENT_COMMAND == nType )
+ else if ( MouseNotifyEvent::COMMAND == nType )
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
if ( pCEvt->GetCommand() == COMMAND_CONTEXTMENU )
@@ -1590,8 +1590,8 @@ Size SfxHelpIndexWindow_Impl::GetOptimalSize() const
bool SfxHelpIndexWindow_Impl::PreNotify(NotifyEvent& rNEvt)
{
bool nDone = false;
- sal_uInt16 nType = rNEvt.GetType();
- if ( EVENT_KEYINPUT == nType && rNEvt.GetKeyEvent() )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( MouseNotifyEvent::KEYINPUT == nType && rNEvt.GetKeyEvent() )
{
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nCode = rKeyCode.GetCode();
@@ -1808,7 +1808,7 @@ TextWin_Impl::~TextWin_Impl()
bool TextWin_Impl::Notify( NotifyEvent& rNEvt )
{
- if( ( rNEvt.GetType() == EVENT_KEYINPUT ) && rNEvt.GetKeyEvent()->GetKeyCode().GetCode() == KEY_TAB )
+ if( ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT ) && rNEvt.GetKeyEvent()->GetKeyCode().GetCode() == KEY_TAB )
return GetParent()->Notify( rNEvt );
else
return DockingWindow::Notify( rNEvt );
@@ -2316,8 +2316,8 @@ void SfxHelpTextWindow_Impl::Resize()
bool SfxHelpTextWindow_Impl::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- sal_uInt16 nType = rNEvt.GetType();
- if ( EVENT_COMMAND == nType && rNEvt.GetCommandEvent() )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( MouseNotifyEvent::COMMAND == nType && rNEvt.GetCommandEvent() )
{
const CommandEvent* pCmdEvt = rNEvt.GetCommandEvent();
vcl::Window* pCmdWin = rNEvt.GetWindow();
@@ -2410,7 +2410,7 @@ bool SfxHelpTextWindow_Impl::PreNotify( NotifyEvent& rNEvt )
nDone = true;
}
}
- else if ( EVENT_KEYINPUT == nType && rNEvt.GetKeyEvent() )
+ else if ( MouseNotifyEvent::KEYINPUT == nType && rNEvt.GetKeyEvent() )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKEvt->GetKeyCode();
@@ -3002,7 +3002,7 @@ SfxHelpWindow_Impl::~SfxHelpWindow_Impl()
bool SfxHelpWindow_Impl::PreNotify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
// Backward == <ALT><LEFT> or <BACKSPACE> Forward == <ALT><RIGHT>
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
diff --git a/sfx2/source/control/thumbnailviewitem.cxx b/sfx2/source/control/thumbnailviewitem.cxx
index ae4fea2dba1e..040eb186cce2 100644
--- a/sfx2/source/control/thumbnailviewitem.cxx
+++ b/sfx2/source/control/thumbnailviewitem.cxx
@@ -75,7 +75,7 @@ ResizableMultiLineEdit::~ResizableMultiLineEdit ()
bool ResizableMultiLineEdit::PreNotify(NotifyEvent& rNEvt)
{
bool nDone = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent& rKEvt = *rNEvt.GetKeyEvent();
vcl::KeyCode aCode = rKEvt.GetKeyCode();
@@ -92,7 +92,7 @@ bool ResizableMultiLineEdit::PreNotify(NotifyEvent& rNEvt)
break;
}
}
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS && !mbIsInGrabFocus )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS && !mbIsInGrabFocus )
{
mpItem->setTitle( GetText() );
mpItem->setEditTitle(false, false);
diff --git a/sfx2/source/dialog/backingwindow.cxx b/sfx2/source/dialog/backingwindow.cxx
index 02bbb08586e4..95084beb5504 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -374,7 +374,7 @@ void BackingWindow::Paint( const Rectangle& )
bool BackingWindow::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode(pEvt->GetKeyCode());
@@ -409,7 +409,7 @@ bool BackingWindow::PreNotify( NotifyEvent& rNEvt )
bool BackingWindow::Notify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
// try the 'normal' accelerators (so that eg. Ctrl+Q works)
if( !mpAccExec )
diff --git a/sfx2/source/dialog/basedlgs.cxx b/sfx2/source/dialog/basedlgs.cxx
index 07e18cb68302..dbabdba1fa9f 100644
--- a/sfx2/source/dialog/basedlgs.cxx
+++ b/sfx2/source/dialog/basedlgs.cxx
@@ -329,17 +329,17 @@ void SfxModelessDialog::Init(SfxBindings *pBindinx, SfxChildWindow *pCW)
*/
bool SfxModelessDialog::Notify( NotifyEvent& rEvt )
{
- if ( rEvt.GetType() == EVENT_GETFOCUS )
+ if ( rEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
pBindings->SetActiveFrame( pImp->pMgr->GetFrame() );
pImp->pMgr->Activate_Impl();
}
- else if ( rEvt.GetType() == EVENT_LOSEFOCUS && !HasChildPathFocus() )
+ else if ( rEvt.GetType() == MouseNotifyEvent::LOSEFOCUS && !HasChildPathFocus() )
{
pBindings->SetActiveFrame( ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame > () );
pImp->pMgr->Deactivate_Impl();
}
- else if( rEvt.GetType() == EVENT_KEYINPUT )
+ else if( rEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
// First, allow KeyInput for Dialog functions ( TAB etc. )
if ( !ModelessDialog::Notify( rEvt ) && SfxViewShell::Current() )
@@ -417,12 +417,12 @@ bool SfxFloatingWindow::Notify( NotifyEvent& rEvt )
*/
{
- if ( rEvt.GetType() == EVENT_GETFOCUS )
+ if ( rEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
pBindings->SetActiveFrame( pImp->pMgr->GetFrame() );
pImp->pMgr->Activate_Impl();
}
- else if ( rEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( !HasChildPathFocus() )
{
@@ -430,7 +430,7 @@ bool SfxFloatingWindow::Notify( NotifyEvent& rEvt )
pImp->pMgr->Deactivate_Impl();
}
}
- else if( rEvt.GetType() == EVENT_KEYINPUT )
+ else if( rEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
// First, allow KeyInput for Dialog functions
if ( !FloatingWindow::Notify( rEvt ) && SfxViewShell::Current() )
diff --git a/sfx2/source/dialog/dockwin.cxx b/sfx2/source/dialog/dockwin.cxx
index 1f84bd2f0a7b..fa4c31cc056c 100644
--- a/sfx2/source/dialog/dockwin.cxx
+++ b/sfx2/source/dialog/dockwin.cxx
@@ -1767,7 +1767,7 @@ Size SfxDockingWindow::GetMinOutputSizePixel() const
bool SfxDockingWindow::Notify( NotifyEvent& rEvt )
{
- if ( rEvt.GetType() == EVENT_GETFOCUS )
+ if ( rEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if (pMgr != NULL)
pBindings->SetActiveFrame( pMgr->GetFrame() );
@@ -1783,7 +1783,7 @@ bool SfxDockingWindow::Notify( NotifyEvent& rEvt )
DockingWindow::Notify( rEvt );
return true;
}
- else if( rEvt.GetType() == EVENT_KEYINPUT )
+ else if( rEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
// First, allow KeyInput for Dialog functions
if ( !DockingWindow::Notify( rEvt ) && SfxViewShell::Current() )
@@ -1791,7 +1791,7 @@ bool SfxDockingWindow::Notify( NotifyEvent& rEvt )
return SfxViewShell::Current()->GlobalKeyInput_Impl( *rEvt.GetKeyEvent() );
return true;
}
- else if ( rEvt.GetType() == EVENT_LOSEFOCUS && !HasChildPathFocus() )
+ else if ( rEvt.GetType() == MouseNotifyEvent::LOSEFOCUS && !HasChildPathFocus() )
{
pBindings->SetActiveFrame( NULL );
if (pMgr != NULL)
diff --git a/sfx2/source/dialog/partwnd.cxx b/sfx2/source/dialog/partwnd.cxx
index 245dd612308f..6420558452e8 100644
--- a/sfx2/source/dialog/partwnd.cxx
+++ b/sfx2/source/dialog/partwnd.cxx
@@ -181,7 +181,7 @@ bool SfxPartDockWnd_Impl::QueryClose()
bool SfxPartDockWnd_Impl::Notify( NotifyEvent& rEvt )
{
- if( rEvt.GetType() == EVENT_GETFOCUS )
+ if( rEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
SfxChildWindow* pChild = GetChildWindow_Impl();
if( pChild )
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 72c5a18a1c73..8b8e1bf210be 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -206,7 +206,7 @@ IMPL_LINK_NOARG(DropListBox_Impl, OnAsyncExecuteDrop)
bool DropListBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool nRet = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
if(!rKeyCode.GetModifier())
@@ -423,7 +423,7 @@ bool StyleTreeListBox_Impl::Notify( NotifyEvent& rNEvt )
// handle <RETURN> as double click
bool nRet = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const vcl::KeyCode& rKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
if ( !rKeyCode.GetModifier() && KEY_RETURN == rKeyCode.GetCode() )
diff --git a/sfx2/source/sidebar/Deck.cxx b/sfx2/source/sidebar/Deck.cxx
index 6e2f3919ffc1..534bd306027d 100644
--- a/sfx2/source/sidebar/Deck.cxx
+++ b/sfx2/source/sidebar/Deck.cxx
@@ -190,7 +190,7 @@ void Deck::DataChanged (const DataChangedEvent& rEvent)
bool Deck::Notify (NotifyEvent& rEvent)
{
- if (rEvent.GetType() == EVENT_COMMAND)
+ if (rEvent.GetType() == MouseNotifyEvent::COMMAND)
{
CommandEvent* pCommandEvent = reinterpret_cast<CommandEvent*>(rEvent.GetData());
if (pCommandEvent != NULL)
diff --git a/sfx2/source/sidebar/PopupContainer.cxx b/sfx2/source/sidebar/PopupContainer.cxx
index 97566fba0a7a..92e5e20f37a3 100644
--- a/sfx2/source/sidebar/PopupContainer.cxx
+++ b/sfx2/source/sidebar/PopupContainer.cxx
@@ -39,7 +39,7 @@ PopupContainer::~PopupContainer (void)
long PopupContainer::Notify (NotifyEvent& rEvent)
{
- if (rEvent.GetType() == EVENT_LOSEFOCUS)
+ if (rEvent.GetType() == MouseNotifyEvent::LOSEFOCUS)
{
if( ! HasChildPathFocus(sal_True))
EndPopupMode();
diff --git a/sfx2/source/sidebar/SidebarToolBox.cxx b/sfx2/source/sidebar/SidebarToolBox.cxx
index 0f038a13c79b..506af77bc3b2 100644
--- a/sfx2/source/sidebar/SidebarToolBox.cxx
+++ b/sfx2/source/sidebar/SidebarToolBox.cxx
@@ -120,7 +120,7 @@ void SidebarToolBox::Paint (const Rectangle& rRect)
bool SidebarToolBox::Notify (NotifyEvent& rEvent)
{
- if (rEvent.GetType() == EVENT_KEYINPUT)
+ if (rEvent.GetType() == MouseNotifyEvent::KEYINPUT)
{
if (rEvent.GetKeyEvent()->GetKeyCode().GetCode() == KEY_TAB)
{
diff --git a/sfx2/source/view/frame2.cxx b/sfx2/source/view/frame2.cxx
index 5b3a6ccac95a..037d7ea525ae 100644
--- a/sfx2/source/view/frame2.cxx
+++ b/sfx2/source/view/frame2.cxx
@@ -107,7 +107,7 @@ bool SfxFrameWindow_Impl::Notify( NotifyEvent& rNEvt )
if ( !pView || !pView->GetObjectShell() )
return Window::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if ( pView->GetViewShell() && !pView->GetViewShell()->GetUIActiveIPClient_Impl() && !pFrame->IsInPlace() )
{
@@ -120,17 +120,17 @@ bool SfxFrameWindow_Impl::Notify( NotifyEvent& rNEvt )
pView->GetBindings().Invalidate( SID_PASTE_SPECIAL );
return true;
}
- else if( rNEvt.GetType() == EVENT_KEYINPUT )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( pView->GetViewShell()->KeyInput( *rNEvt.GetKeyEvent() ) )
return true;
}
- else if ( rNEvt.GetType() == EVENT_EXECUTEDIALOG /*|| rNEvt.GetType() == EVENT_INPUTDISABLE*/ )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::EXECUTEDIALOG /*|| rNEvt.GetType() == MouseNotifyEvent::INPUTDISABLE*/ )
{
pView->SetModalMode( true );
return true;
}
- else if ( rNEvt.GetType() == EVENT_ENDEXECUTEDIALOG /*|| rNEvt.GetType() == EVENT_INPUTENABLE*/ )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::ENDEXECUTEDIALOG /*|| rNEvt.GetType() == MouseNotifyEvent::INPUTENABLE*/ )
{
pView->SetModalMode( false );
return true;
@@ -141,15 +141,15 @@ bool SfxFrameWindow_Impl::Notify( NotifyEvent& rNEvt )
bool SfxFrameWindow_Impl::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
- if ( nType == EVENT_KEYINPUT || nType == EVENT_KEYUP )
+ MouseNotifyEvent nType = rNEvt.GetType();
+ if ( nType == MouseNotifyEvent::KEYINPUT || nType == MouseNotifyEvent::KEYUP )
{
SfxViewFrame* pView = pFrame->GetCurrentViewFrame();
SfxViewShell* pShell = pView ? pView->GetViewShell() : NULL;
if ( pShell && pShell->HasKeyListeners_Impl() && pShell->HandleNotifyEvent_Impl( rNEvt ) )
return true;
}
- else if ( nType == EVENT_MOUSEBUTTONUP || nType == EVENT_MOUSEBUTTONDOWN )
+ else if ( nType == MouseNotifyEvent::MOUSEBUTTONUP || nType == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
vcl::Window* pWindow = rNEvt.GetWindow();
SfxViewFrame* pView = pFrame->GetCurrentViewFrame();
@@ -160,7 +160,7 @@ bool SfxFrameWindow_Impl::PreNotify( NotifyEvent& rNEvt )
return true;
}
- if ( nType == EVENT_MOUSEBUTTONDOWN )
+ if ( nType == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
vcl::Window* pWindow = rNEvt.GetWindow();
const MouseEvent* pMEvent = rNEvt.GetMouseEvent();
diff --git a/sfx2/source/view/printer.cxx b/sfx2/source/view/printer.cxx
index 7ade26dc6c68..e5de62ccd922 100644
--- a/sfx2/source/view/printer.cxx
+++ b/sfx2/source/view/printer.cxx
@@ -253,7 +253,7 @@ short SfxPrintOptionsDialog::Execute()
bool SfxPrintOptionsDialog::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( rNEvt.GetKeyEvent()->GetKeyCode().GetCode() == KEY_F1 && pDlgImpl->mbHelpDisabled )
return true; // help disabled -> <F1> does nothing
diff --git a/sfx2/source/view/userinputinterception.cxx b/sfx2/source/view/userinputinterception.cxx
index 327f40f429b2..a92b575d42d1 100644
--- a/sfx2/source/view/userinputinterception.cxx
+++ b/sfx2/source/view/userinputinterception.cxx
@@ -171,13 +171,13 @@ namespace sfx2
{
Reference < XInterface > xHoldAlive( m_pData->m_rControllerImpl );
- sal_uInt16 nType = _rEvent.GetType();
+ MouseNotifyEvent nType = _rEvent.GetType();
bool bHandled = false;
switch ( nType )
{
- case EVENT_KEYINPUT:
- case EVENT_KEYUP:
+ case MouseNotifyEvent::KEYINPUT:
+ case MouseNotifyEvent::KEYUP:
{
KeyEvent aEvent;
lcl_initKeyEvent( aEvent, *_rEvent.GetKeyEvent() );
@@ -193,7 +193,7 @@ namespace sfx2
try
{
- if ( nType == EVENT_KEYINPUT )
+ if ( nType == MouseNotifyEvent::KEYINPUT )
bHandled = xHandler->keyPressed( aEvent );
else
bHandled = xHandler->keyReleased( aEvent );
@@ -214,8 +214,8 @@ namespace sfx2
}
break;
- case EVENT_MOUSEBUTTONDOWN:
- case EVENT_MOUSEBUTTONUP:
+ case MouseNotifyEvent::MOUSEBUTTONDOWN:
+ case MouseNotifyEvent::MOUSEBUTTONUP:
{
MouseEvent aEvent;
lcl_initMouseEvent( aEvent, *_rEvent.GetMouseEvent() );
@@ -231,7 +231,7 @@ namespace sfx2
try
{
- if ( nType == EVENT_MOUSEBUTTONDOWN )
+ if ( nType == MouseNotifyEvent::MOUSEBUTTONDOWN )
bHandled = xHandler->mousePressed( aEvent );
else
bHandled = xHandler->mouseReleased( aEvent );
diff --git a/svtools/source/brwbox/ebbcontrols.cxx b/svtools/source/brwbox/ebbcontrols.cxx
index 2d12692c74a2..6314bfadf6e8 100644
--- a/svtools/source/brwbox/ebbcontrols.cxx
+++ b/svtools/source/brwbox/ebbcontrols.cxx
@@ -54,7 +54,7 @@ namespace svt
{
switch (rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if (!IsInDropDown())
{
const KeyEvent *pEvt = rNEvt.GetKeyEvent();
@@ -162,7 +162,7 @@ namespace svt
{
switch (rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if (!IsInDropDown())
{
const KeyEvent *pEvt = rNEvt.GetKeyEvent();
@@ -328,10 +328,10 @@ namespace svt
{
switch (rEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
ShowFocus(aFocusRect);
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
HideFocus();
}
return Control::PreNotify(rEvt);
@@ -572,7 +572,7 @@ namespace svt
bool MultiLineTextCell::PreNotify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( IsWindowOrChild( rNEvt.GetWindow() ) )
{
diff --git a/svtools/source/brwbox/editbrowsebox.cxx b/svtools/source/brwbox/editbrowsebox.cxx
index e009e82c885d..a95b68b3198a 100644
--- a/svtools/source/brwbox/editbrowsebox.cxx
+++ b/svtools/source/brwbox/editbrowsebox.cxx
@@ -613,7 +613,7 @@ namespace svt
{
switch (rEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if ( (IsEditing() && Controller()->GetWindow().HasChildPathFocus())
|| rEvt.GetWindow() == &GetDataWindow()
|| (!IsEditing() && HasChildPathFocus())
@@ -738,11 +738,11 @@ namespace svt
{
switch (rEvt.GetType())
{
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
DetermineFocus( getRealGetFocusFlags( this ) );
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
DetermineFocus( 0 );
break;
}
diff --git a/svtools/source/contnr/imivctl1.cxx b/svtools/source/contnr/imivctl1.cxx
index cbcfb74d4924..b4f9fb20dfbe 100644
--- a/svtools/source/contnr/imivctl1.cxx
+++ b/svtools/source/contnr/imivctl1.cxx
@@ -3387,7 +3387,7 @@ void IcnViewEdit_Impl::KeyInput( const KeyEvent& rKEvt )
bool IcnViewEdit_Impl::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( !bAlreadyInCallback &&
((!Application::GetFocusWindow()) || !IsChild(Application::GetFocusWindow())))
diff --git a/svtools/source/contnr/simptabl.cxx b/svtools/source/contnr/simptabl.cxx
index 2422bba2efb8..c5d024cde996 100644
--- a/svtools/source/contnr/simptabl.cxx
+++ b/svtools/source/contnr/simptabl.cxx
@@ -45,7 +45,7 @@ void SvSimpleTableContainer::SetTable(SvSimpleTable* pTable)
bool SvSimpleTableContainer::PreNotify( NotifyEvent& rNEvt )
{
bool nResult = true;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const vcl::KeyCode& aKeyCode = rNEvt.GetKeyEvent()->GetKeyCode();
sal_uInt16 nKey = aKeyCode.GetCode();
diff --git a/svtools/source/control/calendar.cxx b/svtools/source/control/calendar.cxx
index 3a27921ea1d7..5ab89ee57e6a 100644
--- a/svtools/source/control/calendar.cxx
+++ b/svtools/source/control/calendar.cxx
@@ -2359,7 +2359,7 @@ void ImplCFieldFloatWin::ArrangeButtons()
bool ImplCFieldFloatWin::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
if ( pKEvt->GetKeyCode().GetCode() == KEY_RETURN )
diff --git a/svtools/source/control/fileurlbox.cxx b/svtools/source/control/fileurlbox.cxx
index 5ed40d77eaac..8437040b5706 100644
--- a/svtools/source/control/fileurlbox.cxx
+++ b/svtools/source/control/fileurlbox.cxx
@@ -56,7 +56,7 @@ namespace svt
{
switch ( _rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if ( ( GetSubEdit() == _rNEvt.GetWindow() )
&& ( KEY_RETURN == _rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
&& ( IsInDropDown() )
@@ -64,7 +64,7 @@ namespace svt
m_sPreservedText = GetURL();
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
if ( IsWindowOrChild( _rNEvt.GetWindow() ) )
DisplayURL( GetText() );
break;
@@ -78,7 +78,7 @@ namespace svt
{
switch ( _rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
if ( ( GetSubEdit() == _rNEvt.GetWindow() )
&& ( KEY_RETURN == _rNEvt.GetKeyEvent()->GetKeyCode().GetCode() )
&& ( IsInDropDown() )
diff --git a/svtools/source/control/fmtfield.cxx b/svtools/source/control/fmtfield.cxx
index 3cdd68082dcd..37533abc9a51 100644
--- a/svtools/source/control/fmtfield.cxx
+++ b/svtools/source/control/fmtfield.cxx
@@ -532,7 +532,7 @@ void FormattedField::ImplSetTextImpl(const OUString& rNew, Selection* pNewSel)
bool FormattedField::PreNotify(NotifyEvent& rNEvt)
{
- if (rNEvt.GetType() == EVENT_KEYINPUT)
+ if (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT)
m_aLastSelection = GetSelection();
return SpinField::PreNotify(rNEvt);
}
@@ -763,7 +763,7 @@ void FormattedField::ReFormat()
bool FormattedField::Notify(NotifyEvent& rNEvt)
{
- if ((rNEvt.GetType() == EVENT_KEYINPUT) && !IsReadOnly())
+ if ((rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !IsReadOnly())
{
const KeyEvent& rKEvt = *rNEvt.GetKeyEvent();
sal_uInt16 nMod = rKEvt.GetKeyCode().GetModifier();
@@ -782,7 +782,7 @@ bool FormattedField::Notify(NotifyEvent& rNEvt)
}
}
- if ((rNEvt.GetType() == EVENT_COMMAND) && !IsReadOnly())
+ if ((rNEvt.GetType() == MouseNotifyEvent::COMMAND) && !IsReadOnly())
{
const CommandEvent* pCommand = rNEvt.GetCommandEvent();
if (pCommand->GetCommand() == COMMAND_WHEEL)
@@ -798,7 +798,7 @@ bool FormattedField::Notify(NotifyEvent& rNEvt)
}
}
- if (rNEvt.GetType() == EVENT_LOSEFOCUS)
+ if (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS)
{
// Sonderbehandlung fuer leere Texte
if (GetText().isEmpty())
diff --git a/svtools/source/control/inettbc.cxx b/svtools/source/control/inettbc.cxx
index 0a114737a8d9..d125f3eed4bd 100644
--- a/svtools/source/control/inettbc.cxx
+++ b/svtools/source/control/inettbc.cxx
@@ -1095,7 +1095,7 @@ void SvtURLBox::Modify()
bool SvtURLBox::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetWindow() == GetSubEdit() && rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetWindow() == GetSubEdit() && rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent& rEvent = *rNEvt.GetKeyEvent();
@@ -1135,14 +1135,14 @@ void SvtURLBox::AutoCompleteHandler( Edit* )
bool SvtURLBox::Notify( NotifyEvent &rEvt )
{
- if ( EVENT_GETFOCUS == rEvt.GetType() )
+ if ( MouseNotifyEvent::GETFOCUS == rEvt.GetType() )
{
#ifndef UNX
// pb: don't select automatically on unix #93251#
SetSelection( Selection( 0, GetText().getLength() ) );
#endif
}
- else if ( EVENT_LOSEFOCUS == rEvt.GetType() )
+ else if ( MouseNotifyEvent::LOSEFOCUS == rEvt.GetType() )
{
if( GetText().isEmpty() )
ClearModifyFlag();
diff --git a/svtools/source/control/roadmap.cxx b/svtools/source/control/roadmap.cxx
index ce709005dbd2..093390848d32 100644
--- a/svtools/source/control/roadmap.cxx
+++ b/svtools/source/control/roadmap.cxx
@@ -612,7 +612,7 @@ namespace svt
bool ORoadmap::PreNotify( NotifyEvent& _rNEvt )
{
// capture KeyEvents for taskpane cycling
- if ( _rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( _rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
vcl::Window* pWindow = _rNEvt.GetWindow();
RoadmapItem* pItem = GetByPointer( pWindow );
diff --git a/svtools/source/control/tabbar.cxx b/svtools/source/control/tabbar.cxx
index 9fa8b99f7d23..36d8ce0105bc 100644
--- a/svtools/source/control/tabbar.cxx
+++ b/svtools/source/control/tabbar.cxx
@@ -124,7 +124,7 @@ void ImplTabButton::Command( const CommandEvent& rCEvt )
bool ImplTabButton::PreNotify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if ( GetParent()->IsInEditMode() )
{
@@ -275,7 +275,7 @@ TabBarEdit::TabBarEdit( TabBar* pParent, WinBits nWinStyle ) :
bool TabBarEdit::PreNotify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
if ( !pKEvt->GetKeyCode().GetModifier() )
diff --git a/svtools/source/control/urlcontrol.cxx b/svtools/source/control/urlcontrol.cxx
index e22b6b351c26..81a1969bf102 100644
--- a/svtools/source/control/urlcontrol.cxx
+++ b/svtools/source/control/urlcontrol.cxx
@@ -44,7 +44,7 @@ namespace svt
bool OFileURLControl::PreNotify( NotifyEvent& _rNEvt )
{
if (GetSubEdit() == _rNEvt.GetWindow())
- if (EVENT_KEYINPUT == _rNEvt.GetType())
+ if (MouseNotifyEvent::KEYINPUT == _rNEvt.GetType())
if (KEY_RETURN == _rNEvt.GetKeyEvent()->GetKeyCode().GetCode())
if (IsInDropDown())
m_sPreservedText = GetURL();
@@ -55,7 +55,7 @@ namespace svt
bool OFileURLControl::Notify( NotifyEvent& _rNEvt )
{
if (GetSubEdit() == _rNEvt.GetWindow())
- if (EVENT_KEYINPUT == _rNEvt.GetType())
+ if (MouseNotifyEvent::KEYINPUT == _rNEvt.GetType())
if (KEY_RETURN == _rNEvt.GetKeyEvent()->GetKeyCode().GetCode())
if (IsInDropDown())
{
diff --git a/svtools/source/dialogs/addresstemplate.cxx b/svtools/source/dialogs/addresstemplate.cxx
index bfc972a50bf0..5fca301bd266 100644
--- a/svtools/source/dialogs/addresstemplate.cxx
+++ b/svtools/source/dialogs/addresstemplate.cxx
@@ -1230,7 +1230,7 @@ void AssignmentPersistentData::Commit()
{
switch (_rNEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = _rNEvt.GetKeyEvent();
sal_uInt16 nCode = pKeyEvent->GetKeyCode().GetCode();
diff --git a/svtools/source/dialogs/prnsetup.cxx b/svtools/source/dialogs/prnsetup.cxx
index d5fe5fa9b394..ddadba678879 100644
--- a/svtools/source/dialogs/prnsetup.cxx
+++ b/svtools/source/dialogs/prnsetup.cxx
@@ -313,7 +313,7 @@ IMPL_LINK_NOARG(PrinterSetupDialog, ImplChangePrinterHdl)
bool PrinterSetupDialog::Notify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_GETFOCUS) && IsReallyVisible() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS) && IsReallyVisible() )
ImplStatusHdl( &maStatusTimer );
return ModalDialog::Notify( rNEvt );
diff --git a/svtools/source/dialogs/wizdlg.cxx b/svtools/source/dialogs/wizdlg.cxx
index 6a6a4b60b01c..ed8e29051e8e 100644
--- a/svtools/source/dialogs/wizdlg.cxx
+++ b/svtools/source/dialogs/wizdlg.cxx
@@ -429,7 +429,7 @@ void WizardDialog::StateChanged( StateChangedType nType )
bool WizardDialog::Notify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && mpPrevBtn && mpNextBtn )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && mpPrevBtn && mpNextBtn )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/svtools/source/edit/editsyntaxhighlighter.cxx b/svtools/source/edit/editsyntaxhighlighter.cxx
index 1410921320f7..8b8bbb6228fa 100644
--- a/svtools/source/edit/editsyntaxhighlighter.cxx
+++ b/svtools/source/edit/editsyntaxhighlighter.cxx
@@ -115,7 +115,7 @@ void MultiLineEditSyntaxHighlight::DoBracketHilight(sal_uInt16 nKey)
bool MultiLineEditSyntaxHighlight::PreNotify( NotifyEvent& rNEvt )
{
- if ( mbDoBracketHilight && (rNEvt.GetType() == EVENT_KEYINPUT) )
+ if ( mbDoBracketHilight && (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) )
DoBracketHilight(rNEvt.GetKeyEvent()->GetCharCode());
return MultiLineEdit::PreNotify(rNEvt);
diff --git a/svtools/source/hatchwindow/ipwin.cxx b/svtools/source/hatchwindow/ipwin.cxx
index 5ddfba33b8a6..d347ad41e645 100644
--- a/svtools/source/hatchwindow/ipwin.cxx
+++ b/svtools/source/hatchwindow/ipwin.cxx
@@ -619,7 +619,7 @@ void SvResizeWindow::Paint( const Rectangle & /*rRect*/ )
bool SvResizeWindow::PreNotify( NotifyEvent& rEvt )
{
- if ( rEvt.GetType() == EVENT_GETFOCUS && !m_bActive )
+ if ( rEvt.GetType() == MouseNotifyEvent::GETFOCUS && !m_bActive )
{
m_bActive = true;
m_pWrapper->Activated();
@@ -630,7 +630,7 @@ bool SvResizeWindow::PreNotify( NotifyEvent& rEvt )
bool SvResizeWindow::Notify( NotifyEvent& rEvt )
{
- if ( rEvt.GetType() == EVENT_LOSEFOCUS && m_bActive )
+ if ( rEvt.GetType() == MouseNotifyEvent::LOSEFOCUS && m_bActive )
{
bool bHasFocus = HasChildPathFocus(true);
if ( !bHasFocus )
diff --git a/svtools/source/table/tabledatawindow.cxx b/svtools/source/table/tabledatawindow.cxx
index 80a0557b1335..9b5bcc5538f4 100644
--- a/svtools/source/table/tabledatawindow.cxx
+++ b/svtools/source/table/tabledatawindow.cxx
@@ -213,7 +213,7 @@ namespace svt { namespace table
bool TableDataWindow::Notify(NotifyEvent& rNEvt )
{
bool nDone = false;
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent& rCEvt = *rNEvt.GetCommandEvent();
if ( rCEvt.GetCommand() == COMMAND_WHEEL )
diff --git a/svtools/source/toolpanel/toolpaneldeck.cxx b/svtools/source/toolpanel/toolpaneldeck.cxx
index 27dfa5146c0f..af00abb8c204 100644
--- a/svtools/source/toolpanel/toolpaneldeck.cxx
+++ b/svtools/source/toolpanel/toolpaneldeck.cxx
@@ -447,7 +447,7 @@ namespace svt
bool ToolPanelDeck::Notify( NotifyEvent& i_rNotifyEvent )
{
bool bHandled = false;
- if ( i_rNotifyEvent.GetType() == EVENT_KEYINPUT )
+ if ( i_rNotifyEvent.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pEvent = i_rNotifyEvent.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pEvent->GetKeyCode();
diff --git a/svx/source/dialog/rubydialog.cxx b/svx/source/dialog/rubydialog.cxx
index fc8bd10dbd3c..c44d7b25af9b 100644
--- a/svx/source/dialog/rubydialog.cxx
+++ b/svx/source/dialog/rubydialog.cxx
@@ -890,7 +890,7 @@ void RubyEdit::GetFocus()
bool RubyEdit::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKeyCode = pKEvt->GetKeyCode();
diff --git a/svx/source/fmcomp/gridctrl.cxx b/svx/source/fmcomp/gridctrl.cxx
index ddd46801a458..bf271b37b973 100644
--- a/svx/source/fmcomp/gridctrl.cxx
+++ b/svx/source/fmcomp/gridctrl.cxx
@@ -3198,7 +3198,7 @@ bool DbGridControl::PreNotify(NotifyEvent& rEvt)
switch (rEvt.GetType())
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = rEvt.GetKeyEvent();
diff --git a/svx/source/form/datanavi.cxx b/svx/source/form/datanavi.cxx
index a9813718e8d0..34e71ce831b6 100644
--- a/svx/source/form/datanavi.cxx
+++ b/svx/source/form/datanavi.cxx
@@ -1019,7 +1019,7 @@ namespace svxform
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
diff --git a/svx/source/form/tabwin.cxx b/svx/source/form/tabwin.cxx
index 111ab2b5d684..2fd8ad07cbd2 100644
--- a/svx/source/form/tabwin.cxx
+++ b/svx/source/form/tabwin.cxx
@@ -248,7 +248,7 @@ bool FmFieldWin::createSelectionControls( )
bool FmFieldWin::PreNotify( NotifyEvent& _rNEvt )
{
- if ( EVENT_KEYINPUT == _rNEvt.GetType() )
+ if ( MouseNotifyEvent::KEYINPUT == _rNEvt.GetType() )
{
const vcl::KeyCode& rKeyCode = _rNEvt.GetKeyEvent()->GetKeyCode();
if ( ( 0 == rKeyCode.GetModifier() ) && ( KEY_RETURN == rKeyCode.GetCode() ) )
diff --git a/svx/source/gallery2/galbrws1.cxx b/svx/source/gallery2/galbrws1.cxx
index 91309f5b4541..86f5f07005ff 100644
--- a/svx/source/gallery2/galbrws1.cxx
+++ b/svx/source/gallery2/galbrws1.cxx
@@ -92,14 +92,14 @@ bool GalleryThemeListBox::PreNotify( NotifyEvent& rNEvt )
{
bool bDone = false;
- if( rNEvt.GetType() == EVENT_COMMAND )
+ if( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
if( pCEvt && pCEvt->GetCommand() == COMMAND_CONTEXTMENU )
static_cast< GalleryBrowser1* >( GetParent() )->ShowContextMenu();
}
- else if( rNEvt.GetType() == EVENT_KEYINPUT )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
diff --git a/svx/source/sidebar/tools/PopupContainer.cxx b/svx/source/sidebar/tools/PopupContainer.cxx
index dc29c558f986..1c37b6c6bbf0 100644
--- a/svx/source/sidebar/tools/PopupContainer.cxx
+++ b/svx/source/sidebar/tools/PopupContainer.cxx
@@ -39,7 +39,7 @@ PopupContainer::~PopupContainer (void)
bool PopupContainer::Notify (NotifyEvent& rEvent)
{
- if (rEvent.GetType() == EVENT_LOSEFOCUS)
+ if (rEvent.GetType() == MouseNotifyEvent::LOSEFOCUS)
{
if ( ! HasChildPathFocus(true))
{
diff --git a/svx/source/tbxctrls/colrctrl.cxx b/svx/source/tbxctrls/colrctrl.cxx
index 3b79190336a8..2713c13c0e66 100644
--- a/svx/source/tbxctrls/colrctrl.cxx
+++ b/svx/source/tbxctrls/colrctrl.cxx
@@ -493,7 +493,7 @@ void SvxColorDockingWindow::GetFocus (void)
bool SvxColorDockingWindow::Notify( NotifyEvent& rNEvt )
{
bool nRet = false;
- if( ( rNEvt.GetType() == EVENT_KEYINPUT ) )
+ if( ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT ) )
{
KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
sal_uInt16 nKeyCode = aKeyEvt.GetKeyCode().GetCode();
diff --git a/svx/source/tbxctrls/grafctrl.cxx b/svx/source/tbxctrls/grafctrl.cxx
index 119d42f14744..ccc885b945ed 100644
--- a/svx/source/tbxctrls/grafctrl.cxx
+++ b/svx/source/tbxctrls/grafctrl.cxx
@@ -368,9 +368,9 @@ void ImplGrafModeControl::Select()
bool ImplGrafModeControl::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
mnCurPos = GetSelectEntryPos();
return ListBox::PreNotify( rNEvt );
@@ -380,7 +380,7 @@ bool ImplGrafModeControl::Notify( NotifyEvent& rNEvt )
{
bool nHandled = ListBox::Notify( rNEvt );
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
diff --git a/svx/source/tbxctrls/itemwin.cxx b/svx/source/tbxctrls/itemwin.cxx
index a74bddb2a113..30e52ece7957 100644
--- a/svx/source/tbxctrls/itemwin.cxx
+++ b/svx/source/tbxctrls/itemwin.cxx
@@ -156,18 +156,18 @@ void SvxLineBox::Select()
bool SvxLineBox::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
switch(nType)
{
- case EVENT_MOUSEBUTTONDOWN:
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::MOUSEBUTTONDOWN:
+ case MouseNotifyEvent::GETFOCUS:
nCurPos = GetSelectEntryPos();
break;
- case EVENT_LOSEFOCUS:
+ case MouseNotifyEvent::LOSEFOCUS:
SelectEntryPos(nCurPos);
break;
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
if( pKEvt->GetKeyCode().GetCode() == KEY_TAB)
@@ -187,7 +187,7 @@ bool SvxLineBox::Notify( NotifyEvent& rNEvt )
{
bool nHandled = LineLB::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
@@ -354,9 +354,9 @@ void SvxMetricField::RefreshDlgUnit()
bool SvxMetricField::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if ( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if ( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
aCurTxt = GetText();
return MetricField::PreNotify( rNEvt );
@@ -368,7 +368,7 @@ bool SvxMetricField::Notify( NotifyEvent& rNEvt )
{
bool nHandled = MetricField::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode& rKey = pKEvt->GetKeyCode();
@@ -442,11 +442,11 @@ SvxFillTypeBox::~SvxFillTypeBox()
bool SvxFillTypeBox::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if ( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if ( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
nCurPos = GetSelectEntryPos();
- else if ( EVENT_LOSEFOCUS == nType
+ else if ( MouseNotifyEvent::LOSEFOCUS == nType
&& Application::GetFocusWindow()
&& !IsWindowOrChild( Application::GetFocusWindow(), true ) )
{
@@ -465,7 +465,7 @@ bool SvxFillTypeBox::Notify( NotifyEvent& rNEvt )
{
bool nHandled = FillTypeLB::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
switch ( pKEvt->GetKeyCode().GetCode() )
@@ -529,9 +529,9 @@ SvxFillAttrBox::~SvxFillAttrBox()
bool SvxFillAttrBox::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if ( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if ( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
nCurPos = GetSelectEntryPos();
return FillAttrLB::PreNotify( rNEvt );
@@ -543,7 +543,7 @@ bool SvxFillAttrBox::Notify( NotifyEvent& rNEvt )
{
bool nHandled = FillAttrLB::Notify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx
index 8216a9f7d3c3..aa3b63eb9412 100644
--- a/svx/source/tbxctrls/tbcontrl.cxx
+++ b/svx/source/tbxctrls/tbcontrl.cxx
@@ -464,11 +464,11 @@ void SvxStyleBox_Impl::SetFamily( SfxStyleFamily eNewFamily )
bool SvxStyleBox_Impl::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if ( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if ( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
nCurSel = GetSelectEntryPos();
- else if ( EVENT_LOSEFOCUS == nType )
+ else if ( MouseNotifyEvent::LOSEFOCUS == nType )
{
// don't handle before our Select() is called
if ( !HasFocus() && !HasChildPathFocus() )
@@ -481,7 +481,7 @@ bool SvxStyleBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
@@ -933,9 +933,9 @@ void SvxFontNameBox_Impl::Update( const SvxFontItem* pFontItem )
bool SvxFontNameBox_Impl::PreNotify( NotifyEvent& rNEvt )
{
- sal_uInt16 nType = rNEvt.GetType();
+ MouseNotifyEvent nType = rNEvt.GetType();
- if ( EVENT_MOUSEBUTTONDOWN == nType || EVENT_GETFOCUS == nType )
+ if ( MouseNotifyEvent::MOUSEBUTTONDOWN == nType || MouseNotifyEvent::GETFOCUS == nType )
{
EnableControls_Impl();
FillList();
@@ -947,10 +947,10 @@ bool SvxFontNameBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool nHandled = false;
mbEndPreview = false;
- if ( rNEvt.GetType() == EVENT_KEYUP )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYUP )
mbEndPreview = true;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
@@ -974,7 +974,7 @@ bool SvxFontNameBox_Impl::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if ( EVENT_LOSEFOCUS == rNEvt.GetType() )
+ else if ( MouseNotifyEvent::LOSEFOCUS == rNEvt.GetType() )
{
vcl::Window* pFocusWin = Application::GetFocusWindow();
if ( !HasFocus() && GetSubEdit() != pFocusWin )
diff --git a/svx/source/tbxctrls/tbunocontroller.cxx b/svx/source/tbxctrls/tbunocontroller.cxx
index 746d387ae951..0317b84e8979 100644
--- a/svx/source/tbxctrls/tbunocontroller.cxx
+++ b/svx/source/tbxctrls/tbunocontroller.cxx
@@ -224,7 +224,7 @@ bool SvxFontSizeBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
@@ -248,7 +248,7 @@ bool SvxFontSizeBox_Impl::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if( EVENT_LOSEFOCUS == rNEvt.GetType() )
+ else if( MouseNotifyEvent::LOSEFOCUS == rNEvt.GetType() )
{
vcl::Window* pFocusWin = Application::GetFocusWindow();
if(!HasFocus() && GetSubEdit() != pFocusWin)
diff --git a/svx/source/tbxctrls/tbunosearchcontrollers.cxx b/svx/source/tbxctrls/tbunosearchcontrollers.cxx
index f84080a0c959..707693de7989 100644
--- a/svx/source/tbxctrls/tbunosearchcontrollers.cxx
+++ b/svx/source/tbxctrls/tbunosearchcontrollers.cxx
@@ -197,7 +197,7 @@ bool FindTextFieldControl::PreNotify( NotifyEvent& rNEvt )
switch ( rNEvt.GetType() )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
{
const KeyEvent* pKeyEvent = rNEvt.GetKeyEvent();
bool bShift = pKeyEvent->GetKeyCode().IsShift();
@@ -243,7 +243,7 @@ bool FindTextFieldControl::PreNotify( NotifyEvent& rNEvt )
break;
}
- case EVENT_GETFOCUS:
+ case MouseNotifyEvent::GETFOCUS:
SetSelection( Selection( SELECTION_MIN, SELECTION_MAX ) );
break;
}
diff --git a/sw/source/ui/dbui/createaddresslistdialog.cxx b/sw/source/ui/dbui/createaddresslistdialog.cxx
index 86aba605789b..b398105e02e4 100644
--- a/sw/source/ui/dbui/createaddresslistdialog.cxx
+++ b/sw/source/ui/dbui/createaddresslistdialog.cxx
@@ -343,7 +343,7 @@ void SwAddressControl_Impl::Command( const CommandEvent& rCEvt )
bool SwAddressControl_Impl::PreNotify( NotifyEvent& rNEvt )
{
- if(rNEvt.GetType() == EVENT_COMMAND)
+ if(rNEvt.GetType() == MouseNotifyEvent::COMMAND)
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
const sal_uInt16 nCmd = pCEvt->GetCommand();
diff --git a/sw/source/ui/dbui/mmaddressblockpage.cxx b/sw/source/ui/dbui/mmaddressblockpage.cxx
index f96c004c1b7f..675b1e8c7b32 100644
--- a/sw/source/ui/dbui/mmaddressblockpage.cxx
+++ b/sw/source/ui/dbui/mmaddressblockpage.cxx
@@ -999,7 +999,7 @@ void SwAssignFieldsControl::Command( const CommandEvent& rCEvt )
bool SwAssignFieldsControl::PreNotify( NotifyEvent& rNEvt )
{
- if(rNEvt.GetType() == EVENT_COMMAND)
+ if(rNEvt.GetType() == MouseNotifyEvent::COMMAND)
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
const sal_uInt16 nCmd = pCEvt->GetCommand();
@@ -1286,12 +1286,12 @@ void AddressMultiLineEdit::Notify(SfxBroadcaster& /*rBC*/, const SfxHint& rHint)
bool AddressMultiLineEdit::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if( EVENT_KEYINPUT == rNEvt.GetType() &&
+ if( MouseNotifyEvent::KEYINPUT == rNEvt.GetType() &&
rNEvt.GetKeyEvent()->GetCharCode())
{
nHandled = true;
}
- else if(EVENT_MOUSEBUTTONDOWN == rNEvt.GetType()) {
+ else if(MouseNotifyEvent::MOUSEBUTTONDOWN == rNEvt.GetType()) {
const MouseEvent *pMEvt = rNEvt.GetMouseEvent();
if(pMEvt->GetClicks() >= 2)
nHandled = true;
diff --git a/sw/source/ui/fldui/fldvar.cxx b/sw/source/ui/fldui/fldvar.cxx
index 7df0addd74f5..79d845a7d767 100644
--- a/sw/source/ui/fldui/fldvar.cxx
+++ b/sw/source/ui/fldui/fldvar.cxx
@@ -1264,7 +1264,7 @@ extern "C" SAL_DLLPUBLIC_EXPORT vcl::Window* SAL_CALL makeSelectionListBox(vcl::
bool SelectionListBox::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = ListBox::PreNotify( rNEvt );
- if ( rNEvt.GetType() == EVENT_KEYUP )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYUP )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -1272,7 +1272,7 @@ bool SelectionListBox::PreNotify( NotifyEvent& rNEvt )
if( aKeyCode.GetCode() == KEY_SPACE && !nModifier)
bCallAddSelection = true;
}
- if ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index 70b06ab6cc20..868a9dc4577e 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -2142,7 +2142,7 @@ void SwTOXEntryTabPage::SetFocus2theAllBtn()
bool SwTOXEntryTabPage::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent& rKEvt = *rNEvt.GetKeyEvent();
vcl::KeyCode aCode = rKEvt.GetKeyCode();
diff --git a/sw/source/ui/misc/bookmark.cxx b/sw/source/ui/misc/bookmark.cxx
index 3fff8c96cb9f..24877e0ccaca 100644
--- a/sw/source/ui/misc/bookmark.cxx
+++ b/sw/source/ui/misc/bookmark.cxx
@@ -217,7 +217,7 @@ sal_Int32 BookmarkCombo::GetSelectEntryPos( sal_Int32 nSelIndex ) const
bool BookmarkCombo::PreNotify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if( EVENT_KEYINPUT == rNEvt.GetType() &&
+ if( MouseNotifyEvent::KEYINPUT == rNEvt.GetType() &&
rNEvt.GetKeyEvent()->GetCharCode() )
{
OUString sKey( rNEvt.GetKeyEvent()->GetCharCode() );
diff --git a/sw/source/uibase/cctrl/actctrl.cxx b/sw/source/uibase/cctrl/actctrl.cxx
index 5d7d156900aa..04f9932c3d83 100644
--- a/sw/source/uibase/cctrl/actctrl.cxx
+++ b/sw/source/uibase/cctrl/actctrl.cxx
@@ -30,7 +30,7 @@ bool NumEditAction::Notify( NotifyEvent& rNEvt )
{
bool nHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
const vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/sw/source/uibase/ribbar/workctrl.cxx b/sw/source/uibase/ribbar/workctrl.cxx
index 1a2862ddfe65..1bdb608d7eb6 100644
--- a/sw/source/uibase/ribbar/workctrl.cxx
+++ b/sw/source/uibase/ribbar/workctrl.cxx
@@ -608,7 +608,7 @@ bool SwZoomBox_Impl::Notify( NotifyEvent& rNEvt )
{
bool bHandled = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
sal_uInt16 nCode = rNEvt.GetKeyEvent()->GetKeyCode().GetCode();
@@ -631,7 +631,7 @@ bool SwZoomBox_Impl::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if ( EVENT_LOSEFOCUS == rNEvt.GetType() )
+ else if ( MouseNotifyEvent::LOSEFOCUS == rNEvt.GetType() )
{
vcl::Window* pFocusWin = Application::GetFocusWindow();
if ( !HasFocus() && GetSubEdit() != pFocusWin )
diff --git a/vcl/inc/window.h b/vcl/inc/window.h
index fe1c9fbaf133..6e6129b1b1b4 100644
--- a/vcl/inc/window.h
+++ b/vcl/inc/window.h
@@ -51,6 +51,7 @@ class VCLXWindow;
class SalFrame;
class SalObject;
enum class MouseEventModifiers;
+enum class MouseNotifyEvent;
namespace com {
namespace sun {
@@ -377,7 +378,7 @@ public:
// helper methods
-bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMouseLeave,
+bool ImplHandleMouseEvent( vcl::Window* pWindow, MouseNotifyEvent nSVEvent, bool bMouseLeave,
long nX, long nY, sal_uIntPtr nMsgTime,
sal_uInt16 nCode, MouseEventModifiers nMode );
void ImplHandleResize( vcl::Window* pWindow, long nNewWidth, long nNewHeight );
diff --git a/vcl/osx/salinst.cxx b/vcl/osx/salinst.cxx
index 5e81c6bf586a..26ff137bc763 100644
--- a/vcl/osx/salinst.cxx
+++ b/vcl/osx/salinst.cxx
@@ -521,7 +521,7 @@ void AquaSalInstance::handleAppDefinedEvent( NSEvent* pEvent )
{
const Point aPoint;
CommandEvent aCEvt( aPoint, COMMAND_MEDIA, FALSE, &nCommand );
- NotifyEvent aNCmdEvt( EVENT_COMMAND, pWindow, &aCEvt );
+ NotifyEvent aNCmdEvt( MouseNotifyEvent::COMMAND, pWindow, &aCEvt );
if ( !ImplCallPreNotify( aNCmdEvt ) )
pWindow->Command( aCEvt );
diff --git a/vcl/source/control/button.cxx b/vcl/source/control/button.cxx
index 8712c22a14fe..afef44381368 100644
--- a/vcl/source/control/button.cxx
+++ b/vcl/source/control/button.cxx
@@ -1496,7 +1496,7 @@ bool PushButton::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( pMouseEvt->IsEnterWindow() || pMouseEvt->IsLeaveWindow() )
{
@@ -2623,7 +2623,7 @@ bool RadioButton::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
@@ -3557,7 +3557,7 @@ bool CheckBox::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
diff --git a/vcl/source/control/combobox.cxx b/vcl/source/control/combobox.cxx
index 329e48a1237b..d35a64bf3006 100644
--- a/vcl/source/control/combobox.cxx
+++ b/vcl/source/control/combobox.cxx
@@ -690,7 +690,7 @@ bool ComboBox::PreNotify( NotifyEvent& rNEvt )
bool ComboBox::Notify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( ( rNEvt.GetType() == EVENT_KEYINPUT ) && ( rNEvt.GetWindow() == mpSubEdit )
+ if( ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT ) && ( rNEvt.GetWindow() == mpSubEdit )
&& !IsReadOnly() )
{
KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
@@ -737,14 +737,14 @@ bool ComboBox::Notify( NotifyEvent& rNEvt )
break;
}
}
- else if ( (rNEvt.GetType() == EVENT_LOSEFOCUS) && mpFloatWin )
+ else if ( (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS) && mpFloatWin )
{
if( mpFloatWin->HasChildPathFocus() )
mpSubEdit->GrabFocus();
else if ( mpFloatWin->IsInPopupMode() && !HasChildPathFocus( true ) )
mpFloatWin->EndPopupMode();
}
- else if( (rNEvt.GetType() == EVENT_COMMAND) &&
+ else if( (rNEvt.GetType() == MouseNotifyEvent::COMMAND) &&
(rNEvt.GetCommandEvent()->GetCommand() == COMMAND_WHEEL) &&
(rNEvt.GetWindow() == mpSubEdit) )
{
@@ -762,7 +762,7 @@ bool ComboBox::Notify( NotifyEvent& rNEvt )
nDone = false; // don't eat this event, let the default handling happen (i.e. scroll the context)
}
}
- else if( ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN ) && ( rNEvt.GetWindow() == &mpImplLB->GetMainWindow() ) )
+ else if( ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN ) && ( rNEvt.GetWindow() == &mpImplLB->GetMainWindow() ) )
{
mpSubEdit->GrabFocus();
}
diff --git a/vcl/source/control/ctrl.cxx b/vcl/source/control/ctrl.cxx
index 3654cbd51b48..612bf94fc2a0 100644
--- a/vcl/source/control/ctrl.cxx
+++ b/vcl/source/control/ctrl.cxx
@@ -243,7 +243,7 @@ OUString Control::GetDisplayText() const
bool Control::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if ( !mbHasControlFocus )
{
@@ -256,7 +256,7 @@ bool Control::Notify( NotifyEvent& rNEvt )
}
else
{
- if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
vcl::Window* pFocusWin = Application::GetFocusWindow();
if ( !pFocusWin || !ImplIsWindowOrChild( pFocusWin ) )
diff --git a/vcl/source/control/field.cxx b/vcl/source/control/field.cxx
index 73d8e9a97a76..bd03aadfd947 100644
--- a/vcl/source/control/field.cxx
+++ b/vcl/source/control/field.cxx
@@ -772,7 +772,7 @@ NumericField::~NumericField()
bool NumericField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplNumericProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -783,9 +783,9 @@ bool NumericField::PreNotify( NotifyEvent& rNEvt )
bool NumericField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -909,7 +909,7 @@ NumericBox::~NumericBox()
bool NumericBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplNumericProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -920,9 +920,9 @@ bool NumericBox::PreNotify( NotifyEvent& rNEvt )
bool NumericBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -1655,7 +1655,7 @@ sal_Int64 MetricField::GetLast( FieldUnit eOutUnit ) const
bool MetricField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplMetricProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -1666,9 +1666,9 @@ bool MetricField::PreNotify( NotifyEvent& rNEvt )
bool MetricField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -1756,7 +1756,7 @@ MetricBox::~MetricBox()
bool MetricBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplMetricProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -1767,9 +1767,9 @@ bool MetricBox::PreNotify( NotifyEvent& rNEvt )
bool MetricBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -1986,7 +1986,7 @@ CurrencyField::~CurrencyField()
bool CurrencyField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplCurrencyProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -1997,9 +1997,9 @@ bool CurrencyField::PreNotify( NotifyEvent& rNEvt )
bool CurrencyField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -2068,7 +2068,7 @@ CurrencyBox::~CurrencyBox()
bool CurrencyBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplCurrencyProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -2079,9 +2079,9 @@ bool CurrencyBox::PreNotify( NotifyEvent& rNEvt )
bool CurrencyBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
diff --git a/vcl/source/control/field2.cxx b/vcl/source/control/field2.cxx
index 326b94673b5f..0a651c7f191c 100644
--- a/vcl/source/control/field2.cxx
+++ b/vcl/source/control/field2.cxx
@@ -826,7 +826,7 @@ PatternField::~PatternField()
bool PatternField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplPatternProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), GetEditMask(), GetLiteralMask(),
IsStrictFormat(), GetFormatFlags(),
@@ -839,9 +839,9 @@ bool PatternField::PreNotify( NotifyEvent& rNEvt )
bool PatternField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -876,7 +876,7 @@ PatternBox::~PatternBox()
bool PatternBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplPatternProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), GetEditMask(), GetLiteralMask(),
IsStrictFormat(), GetFormatFlags(),
@@ -889,9 +889,9 @@ bool PatternBox::PreNotify( NotifyEvent& rNEvt )
bool PatternBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
@@ -1822,7 +1822,7 @@ DateField::~DateField()
bool DateField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && IsStrictFormat() &&
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && IsStrictFormat() &&
( GetExtDateFormat() != XTDATEF_SYSTEM_LONG ) &&
!rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
@@ -1835,9 +1835,9 @@ bool DateField::PreNotify( NotifyEvent& rNEvt )
bool DateField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() )
{
@@ -1925,7 +1925,7 @@ DateBox::~DateBox()
bool DateBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && IsStrictFormat() &&
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && IsStrictFormat() &&
( GetExtDateFormat() != XTDATEF_SYSTEM_LONG ) &&
!rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
@@ -1950,9 +1950,9 @@ void DateBox::DataChanged( const DataChangedEvent& rDCEvt )
bool DateBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() )
{
@@ -2699,7 +2699,7 @@ TimeField::~TimeField()
bool TimeField::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplTimeProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsDuration(), GetFormat(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -2710,9 +2710,9 @@ bool TimeField::PreNotify( NotifyEvent& rNEvt )
bool TimeField::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
{
@@ -2840,7 +2840,7 @@ TimeBox::~TimeBox()
bool TimeBox::PreNotify( NotifyEvent& rNEvt )
{
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) && !rNEvt.GetKeyEvent()->GetKeyCode().IsMod2() )
{
if ( ImplTimeProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsDuration(), GetFormat(), ImplGetLocaleDataWrapper() ) )
return true;
@@ -2851,9 +2851,9 @@ bool TimeBox::PreNotify( NotifyEvent& rNEvt )
bool TimeBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
MarkToBeReformatted( false );
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() && (!GetText().isEmpty() || !IsEmptyFieldValueEnabled()) )
Reformat();
diff --git a/vcl/source/control/ilstbox.cxx b/vcl/source/control/ilstbox.cxx
index 62db0c7afd92..d4a427643387 100644
--- a/vcl/source/control/ilstbox.cxx
+++ b/vcl/source/control/ilstbox.cxx
@@ -2494,7 +2494,7 @@ void ImplListBox::DataChanged( const DataChangedEvent& rDCEvt )
bool ImplListBox::Notify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent& rCEvt = *rNEvt.GetCommandEvent();
if ( rCEvt.GetCommand() == COMMAND_WHEEL )
@@ -2622,7 +2622,7 @@ bool ImplWin::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( pMouseEvt->IsEnterWindow() || pMouseEvt->IsLeaveWindow() )
{
@@ -2915,7 +2915,7 @@ ImplListBoxFloatingWindow::ImplListBoxFloatingWindow( vcl::Window* pParent ) :
bool ImplListBoxFloatingWindow::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if( !GetParent()->HasChildPathFocus( true ) )
EndPopupMode();
diff --git a/vcl/source/control/longcurr.cxx b/vcl/source/control/longcurr.cxx
index 3b6bd4570a79..1393de0a589a 100644
--- a/vcl/source/control/longcurr.cxx
+++ b/vcl/source/control/longcurr.cxx
@@ -472,7 +472,7 @@ LongCurrencyField::~LongCurrencyField()
bool LongCurrencyField::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( ImplLongCurrencyProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), GetLocaleDataWrapper() ) )
return true;
@@ -482,11 +482,11 @@ bool LongCurrencyField::PreNotify( NotifyEvent& rNEvt )
bool LongCurrencyField::Notify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_GETFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
MarkToBeReformatted( false );
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() )
{
@@ -550,7 +550,7 @@ LongCurrencyBox::~LongCurrencyBox()
bool LongCurrencyBox::PreNotify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( ImplLongCurrencyProcessKeyInput( GetField(), *rNEvt.GetKeyEvent(), IsStrictFormat(), IsUseThousandSep(), GetLocaleDataWrapper() ) )
return true;
@@ -560,11 +560,11 @@ bool LongCurrencyBox::PreNotify( NotifyEvent& rNEvt )
bool LongCurrencyBox::Notify( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_GETFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
MarkToBeReformatted( false );
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( MustBeReformatted() )
{
diff --git a/vcl/source/control/lstbox.cxx b/vcl/source/control/lstbox.cxx
index ee8884dc04c4..867cea50e705 100644
--- a/vcl/source/control/lstbox.cxx
+++ b/vcl/source/control/lstbox.cxx
@@ -878,7 +878,7 @@ bool ListBox::PreNotify( NotifyEvent& rNEvt )
bool nDone = false;
if ( mpImplLB )
{
- if( ( rNEvt.GetType() == EVENT_KEYINPUT ) && ( rNEvt.GetWindow() == mpImplWin ) )
+ if( ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT ) && ( rNEvt.GetWindow() == mpImplWin ) )
{
KeyEvent aKeyEvt = *rNEvt.GetKeyEvent();
switch( aKeyEvt.GetKeyCode().GetCode() )
@@ -930,12 +930,12 @@ bool ListBox::PreNotify( NotifyEvent& rNEvt )
}
}
}
- else if ( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
if ( IsInDropDown() && !HasChildPathFocus( true ) )
mpFloatWin->EndPopupMode();
}
- else if ( (rNEvt.GetType() == EVENT_COMMAND) &&
+ else if ( (rNEvt.GetType() == MouseNotifyEvent::COMMAND) &&
(rNEvt.GetCommandEvent()->GetCommand() == COMMAND_WHEEL) &&
(rNEvt.GetWindow() == mpImplWin) )
{
diff --git a/vcl/source/control/scrbar.cxx b/vcl/source/control/scrbar.cxx
index 1af0b65f4c8e..06920fe036bc 100644
--- a/vcl/source/control/scrbar.cxx
+++ b/vcl/source/control/scrbar.cxx
@@ -1259,7 +1259,7 @@ bool ScrollBar::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
diff --git a/vcl/source/control/spinbtn.cxx b/vcl/source/control/spinbtn.cxx
index 122aed10c89d..9b16b4753751 100644
--- a/vcl/source/control/spinbtn.cxx
+++ b/vcl/source/control/spinbtn.cxx
@@ -446,7 +446,7 @@ bool SpinButton::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
diff --git a/vcl/source/control/spinfld.cxx b/vcl/source/control/spinfld.cxx
index 97e6633a7dbf..0ab79c9f70a7 100644
--- a/vcl/source/control/spinfld.cxx
+++ b/vcl/source/control/spinfld.cxx
@@ -497,7 +497,7 @@ void SpinField::MouseMove( const MouseEvent& rMEvt )
bool SpinField::Notify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( rNEvt.GetType() == EVENT_KEYINPUT )
+ if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent& rKEvt = *rNEvt.GetKeyEvent();
if ( !IsReadOnly() )
@@ -551,7 +551,7 @@ bool SpinField::Notify( NotifyEvent& rNEvt )
}
}
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
if ( ( rNEvt.GetCommandEvent()->GetCommand() == COMMAND_WHEEL ) && !IsReadOnly() )
{
@@ -856,7 +856,7 @@ bool SpinField::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
diff --git a/vcl/source/control/tabctrl.cxx b/vcl/source/control/tabctrl.cxx
index 2fb87dc3948f..e36acc02ac54 100644
--- a/vcl/source/control/tabctrl.cxx
+++ b/vcl/source/control/tabctrl.cxx
@@ -1533,7 +1533,7 @@ bool TabControl::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
@@ -1581,7 +1581,7 @@ bool TabControl::Notify( NotifyEvent& rNEvt )
{
bool nRet = false;
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
nRet = ImplHandleKeyEvent( *rNEvt.GetKeyEvent() );
return nRet || Control::Notify( rNEvt );
diff --git a/vcl/source/edit/vclmedit.cxx b/vcl/source/edit/vclmedit.cxx
index 7314fa1386c9..0ec3741d03bc 100644
--- a/vcl/source/edit/vclmedit.cxx
+++ b/vcl/source/edit/vclmedit.cxx
@@ -1381,7 +1381,7 @@ void VclMultiLineEdit::Draw( OutputDevice* pDev, const Point& rPos, const Size&
bool VclMultiLineEdit::Notify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( rNEvt.GetType() == EVENT_COMMAND )
+ if( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
nDone = pImpVclMEdit->HandleCommand( *rNEvt.GetCommandEvent() );
}
@@ -1392,7 +1392,7 @@ bool VclMultiLineEdit::PreNotify( NotifyEvent& rNEvt )
{
bool nDone = false;
- if( ( rNEvt.GetType() == EVENT_KEYINPUT ) && ( !GetTextView()->IsCursorEnabled() ) )
+ if( ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT ) && ( !GetTextView()->IsCursorEnabled() ) )
{
const KeyEvent& rKEvent = *rNEvt.GetKeyEvent();
if ( !rKEvent.GetKeyCode().IsShift() && ( rKEvent.GetKeyCode().GetGroup() == KEYGROUP_CURSOR ) )
diff --git a/vcl/source/window/dialog.cxx b/vcl/source/window/dialog.cxx
index 917af60fea41..6848c298dc16 100644
--- a/vcl/source/window/dialog.cxx
+++ b/vcl/source/window/dialog.cxx
@@ -557,7 +557,7 @@ bool Dialog::Notify( NotifyEvent& rNEvt )
bool nRet = SystemWindow::Notify( rNEvt );
if ( !nRet )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
@@ -574,7 +574,7 @@ bool Dialog::Notify( NotifyEvent& rNEvt )
return true;
}
}
- else if ( rNEvt.GetType() == EVENT_GETFOCUS )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
// make sure the dialog is still modal
// changing focus between application frames may
@@ -770,7 +770,7 @@ bool Dialog::ImplStartExecuteModal()
if ( GetParent() )
{
- NotifyEvent aNEvt( EVENT_EXECUTEDIALOG, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::EXECUTEDIALOG, this );
GetParent()->Notify( aNEvt );
}
mbInExecute = true;
@@ -939,7 +939,7 @@ void Dialog::EndDialog( long nResult )
EnableSaveBackground( mbOldSaveBack );
if ( GetParent() )
{
- NotifyEvent aNEvt( EVENT_ENDEXECUTEDIALOG, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::ENDEXECUTEDIALOG, this );
GetParent()->Notify( aNEvt );
}
diff --git a/vcl/source/window/dlgctrl.cxx b/vcl/source/window/dlgctrl.cxx
index 77ac0f17f029..a7d6e7ad9f82 100644
--- a/vcl/source/window/dlgctrl.cxx
+++ b/vcl/source/window/dlgctrl.cxx
@@ -687,11 +687,11 @@ bool Window::ImplDlgCtrl( const KeyEvent& rKEvt, bool bKeyInput )
// in case AROUND is being processed
if ( pTempWindow && (pTempWindow == pSWindow) )
{
- NotifyEvent aNEvt1( EVENT_LOSEFOCUS, pSWindow );
+ NotifyEvent aNEvt1( MouseNotifyEvent::LOSEFOCUS, pSWindow );
if ( !ImplCallPreNotify( aNEvt1 ) )
pSWindow->LoseFocus();
pSWindow->mpWindowImpl->mnGetFocusFlags = nGetFocusFlags | GETFOCUS_AROUND;
- NotifyEvent aNEvt2( EVENT_GETFOCUS, pSWindow );
+ NotifyEvent aNEvt2( MouseNotifyEvent::GETFOCUS, pSWindow );
if ( !ImplCallPreNotify( aNEvt2 ) )
pSWindow->GetFocus();
pSWindow->mpWindowImpl->mnGetFocusFlags = 0;
@@ -819,11 +819,11 @@ bool Window::ImplDlgCtrl( const KeyEvent& rKEvt, bool bKeyInput )
// in case AROUND is being processed
if ( pWindow == pSWindow )
{
- NotifyEvent aNEvt1( EVENT_LOSEFOCUS, pSWindow );
+ NotifyEvent aNEvt1( MouseNotifyEvent::LOSEFOCUS, pSWindow );
if ( !ImplCallPreNotify( aNEvt1 ) )
pSWindow->LoseFocus();
pSWindow->mpWindowImpl->mnGetFocusFlags = nGetFocusFlags | GETFOCUS_AROUND;
- NotifyEvent aNEvt2( EVENT_GETFOCUS, pSWindow );
+ NotifyEvent aNEvt2( MouseNotifyEvent::GETFOCUS, pSWindow );
if ( !ImplCallPreNotify( aNEvt2 ) )
pSWindow->GetFocus();
pSWindow->mpWindowImpl->mnGetFocusFlags = 0;
diff --git a/vcl/source/window/dockwin.cxx b/vcl/source/window/dockwin.cxx
index c487bfe7b390..057a8c525504 100644
--- a/vcl/source/window/dockwin.cxx
+++ b/vcl/source/window/dockwin.cxx
@@ -561,7 +561,7 @@ bool DockingWindow::Notify( NotifyEvent& rNEvt )
if ( mbDockable )
{
- if ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
if ( pMEvt->IsLeft() )
@@ -591,7 +591,7 @@ bool DockingWindow::Notify( NotifyEvent& rNEvt )
}
}
}
- else if( rNEvt.GetType() == EVENT_KEYINPUT )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const vcl::KeyCode& rKey = rNEvt.GetKeyEvent()->GetKeyCode();
if( rKey.GetCode() == KEY_F10 && rKey.GetModifier() &&
diff --git a/vcl/source/window/event.cxx b/vcl/source/window/event.cxx
index 995fd7661a2d..01fb32213ff8 100644
--- a/vcl/source/window/event.cxx
+++ b/vcl/source/window/event.cxx
@@ -57,7 +57,7 @@ bool Window::PreNotify( NotifyEvent& rNEvt )
if ( !bDone )
{
- if( rNEvt.GetType() == EVENT_GETFOCUS )
+ if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
bool bCompoundFocusChanged = false;
if ( mpWindowImpl->mbCompoundControl && !mpWindowImpl->mbCompoundControlHasFocus && HasChildPathFocus() )
@@ -69,7 +69,7 @@ bool Window::PreNotify( NotifyEvent& rNEvt )
if ( bCompoundFocusChanged || ( rNEvt.GetWindow() == this ) )
ImplCallEventListeners( VCLEVENT_WINDOW_GETFOCUS );
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
bool bCompoundFocusChanged = false;
if ( mpWindowImpl->mbCompoundControl && mpWindowImpl->mbCompoundControlHasFocus && !HasChildPathFocus() )
@@ -99,7 +99,7 @@ bool Window::Notify( NotifyEvent& rNEvt )
ImplDockingWindowWrapper *pWrapper = ImplGetDockingManager()->GetDockingWindowWrapper( this );
if( pWrapper && !( !pWrapper->IsFloatingMode() && pWrapper->IsLocked() ) )
{
- if ( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
bool bHit = pWrapper->GetDragArea().IsInside( pMEvt->GetPosPixel() );
@@ -119,7 +119,7 @@ bool Window::Notify( NotifyEvent& rNEvt )
}
}
}
- else if ( rNEvt.GetType() == EVENT_MOUSEMOVE )
+ else if ( rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE )
{
const MouseEvent* pMEvt = rNEvt.GetMouseEvent();
bool bHit = pWrapper->GetDragArea().IsInside( pMEvt->GetPosPixel() );
@@ -142,7 +142,7 @@ bool Window::Notify( NotifyEvent& rNEvt )
return true;
}
}
- else if( rNEvt.GetType() == EVENT_KEYINPUT )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const vcl::KeyCode& rKey = rNEvt.GetKeyEvent()->GetKeyCode();
if( rKey.GetCode() == KEY_F10 && rKey.GetModifier() &&
@@ -166,18 +166,18 @@ bool Window::Notify( NotifyEvent& rNEvt )
if ( (GetStyle() & (WB_DIALOGCONTROL | WB_NODIALOGCONTROL)) == WB_DIALOGCONTROL )
{
// if the parent also has dialog control activated, the parent takes over control
- if ( (rNEvt.GetType() == EVENT_KEYINPUT) || (rNEvt.GetType() == EVENT_KEYUP) )
+ if ( (rNEvt.GetType() == MouseNotifyEvent::KEYINPUT) || (rNEvt.GetType() == MouseNotifyEvent::KEYUP) )
{
if ( ImplIsOverlapWindow() ||
((getNonLayoutRealParent(this)->GetStyle() & (WB_DIALOGCONTROL | WB_NODIALOGCONTROL)) != WB_DIALOGCONTROL) )
{
- nRet = ImplDlgCtrl( *rNEvt.GetKeyEvent(), rNEvt.GetType() == EVENT_KEYINPUT );
+ nRet = ImplDlgCtrl( *rNEvt.GetKeyEvent(), rNEvt.GetType() == MouseNotifyEvent::KEYINPUT );
}
}
- else if ( (rNEvt.GetType() == EVENT_GETFOCUS) || (rNEvt.GetType() == EVENT_LOSEFOCUS) )
+ else if ( (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS) || (rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS) )
{
- ImplDlgCtrlFocusChanged( rNEvt.GetWindow(), rNEvt.GetType() == EVENT_GETFOCUS );
- if ( (rNEvt.GetWindow() == this) && (rNEvt.GetType() == EVENT_GETFOCUS) &&
+ ImplDlgCtrlFocusChanged( rNEvt.GetWindow(), rNEvt.GetType() == MouseNotifyEvent::GETFOCUS );
+ if ( (rNEvt.GetWindow() == this) && (rNEvt.GetType() == MouseNotifyEvent::GETFOCUS) &&
!(GetStyle() & WB_TABSTOP) && !(mpWindowImpl->mnDlgCtrlFlags & WINDOW_DLGCTRL_WANTFOCUS) )
{
sal_uInt16 n = 0;
@@ -322,7 +322,7 @@ CommandEvent ImplTranslateCommandEvent( const CommandEvent& rCEvt, vcl::Window*
void Window::ImplNotifyKeyMouseCommandEventListeners( NotifyEvent& rNEvt )
{
- if( rNEvt.GetType() == EVENT_COMMAND )
+ if( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent* pCEvt = rNEvt.GetCommandEvent();
if ( pCEvt->GetCommand() != COMMAND_CONTEXTMENU )
@@ -352,7 +352,7 @@ void Window::ImplNotifyKeyMouseCommandEventListeners( NotifyEvent& rNEvt )
ImplDelData aDelData;
ImplAddDel( &aDelData );
- if( rNEvt.GetType() == EVENT_MOUSEMOVE )
+ if( rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE )
{
if ( mpWindowImpl->mbCompoundControl || ( rNEvt.GetWindow() == this ) )
{
@@ -365,7 +365,7 @@ void Window::ImplNotifyKeyMouseCommandEventListeners( NotifyEvent& rNEvt )
}
}
}
- else if( rNEvt.GetType() == EVENT_MOUSEBUTTONUP )
+ else if( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONUP )
{
if ( mpWindowImpl->mbCompoundControl || ( rNEvt.GetWindow() == this ) )
{
@@ -378,7 +378,7 @@ void Window::ImplNotifyKeyMouseCommandEventListeners( NotifyEvent& rNEvt )
}
}
}
- else if( rNEvt.GetType() == EVENT_MOUSEBUTTONDOWN )
+ else if( rNEvt.GetType() == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if ( mpWindowImpl->mbCompoundControl || ( rNEvt.GetWindow() == this ) )
{
@@ -391,12 +391,12 @@ void Window::ImplNotifyKeyMouseCommandEventListeners( NotifyEvent& rNEvt )
}
}
}
- else if( rNEvt.GetType() == EVENT_KEYINPUT )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if ( mpWindowImpl->mbCompoundControl || ( rNEvt.GetWindow() == this ) )
ImplCallEventListeners( VCLEVENT_WINDOW_KEYINPUT, (void*)rNEvt.GetKeyEvent() );
}
- else if( rNEvt.GetType() == EVENT_KEYUP )
+ else if( rNEvt.GetType() == MouseNotifyEvent::KEYUP )
{
if ( mpWindowImpl->mbCompoundControl || ( rNEvt.GetWindow() == this ) )
ImplCallEventListeners( VCLEVENT_WINDOW_KEYUP, (void*)rNEvt.GetKeyEvent() );
diff --git a/vcl/source/window/floatwin.cxx b/vcl/source/window/floatwin.cxx
index ec8c6a5566f7..b1534ec7d2c4 100644
--- a/vcl/source/window/floatwin.cxx
+++ b/vcl/source/window/floatwin.cxx
@@ -518,7 +518,7 @@ bool FloatingWindow::Notify( NotifyEvent& rNEvt )
bool nRet = SystemWindow::Notify( rNEvt );
if ( !nRet )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
const KeyEvent* pKEvt = rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = pKEvt->GetKeyCode();
diff --git a/vcl/source/window/layout.cxx b/vcl/source/window/layout.cxx
index bb6e8f1ed0bb..c13e6b461fbe 100644
--- a/vcl/source/window/layout.cxx
+++ b/vcl/source/window/layout.cxx
@@ -1803,7 +1803,7 @@ bool VclScrolledWindow::set_property(const OString &rKey, const OString &rValue)
bool VclScrolledWindow::Notify(NotifyEvent& rNEvt)
{
bool nDone = false;
- if ( rNEvt.GetType() == EVENT_COMMAND )
+ if ( rNEvt.GetType() == MouseNotifyEvent::COMMAND )
{
const CommandEvent& rCEvt = *rNEvt.GetCommandEvent();
if ( rCEvt.GetCommand() == COMMAND_WHEEL )
diff --git a/vcl/source/window/mouse.cxx b/vcl/source/window/mouse.cxx
index 783312f78bf2..054f10bbfd22 100644
--- a/vcl/source/window/mouse.cxx
+++ b/vcl/source/window/mouse.cxx
@@ -153,7 +153,7 @@ void Window::ImplCallMouseMove( sal_uInt16 nMouseCode, bool bModChanged )
nMode |= MouseEventModifiers::SYNTHETIC;
if ( bModChanged )
nMode |= MouseEventModifiers::MODIFIERCHANGED;
- ImplHandleMouseEvent( mpWindowImpl->mpFrameWindow, EVENT_MOUSEMOVE, bLeave, nX, nY, nTime, nCode, nMode );
+ ImplHandleMouseEvent( mpWindowImpl->mpFrameWindow, MouseNotifyEvent::MOUSEMOVE, bLeave, nX, nY, nTime, nCode, nMode );
}
}
@@ -352,7 +352,7 @@ void Window::ImplGrabFocus( sal_uInt16 nFlags )
if ( pOldFocusWindow->IsTracking() &&
(pSVData->maWinData.mnTrackFlags & STARTTRACK_FOCUSCANCEL) )
pOldFocusWindow->EndTracking( ENDTRACK_CANCEL | ENDTRACK_FOCUS );
- NotifyEvent aNEvt( EVENT_LOSEFOCUS, pOldFocusWindow );
+ NotifyEvent aNEvt( MouseNotifyEvent::LOSEFOCUS, pOldFocusWindow );
if ( !ImplCallPreNotify( aNEvt ) )
pOldFocusWindow->LoseFocus();
pOldFocusWindow->ImplCallDeactivateListeners( this );
@@ -380,7 +380,7 @@ void Window::ImplGrabFocus( sal_uInt16 nFlags )
! aOldFocusDel.IsDead() &&
( pOldFocusWindow->GetDialogControlFlags() & WINDOW_DLGCTRL_FLOATWIN_POPUPMODEEND_CANCEL ) )
mpWindowImpl->mnGetFocusFlags |= GETFOCUS_FLOATWIN_POPUPMODEEND_CANCEL;
- NotifyEvent aNEvt( EVENT_GETFOCUS, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::GETFOCUS, this );
if ( !ImplCallPreNotify( aNEvt ) && !aDogTag.IsDead() )
GetFocus();
if( !aDogTag.IsDead() )
@@ -414,21 +414,21 @@ void Window::ImplGrabFocusToDocument( sal_uInt16 nFlags )
void Window::MouseMove( const MouseEvent& rMEvt )
{
- NotifyEvent aNEvt( EVENT_MOUSEMOVE, this, &rMEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::MOUSEMOVE, this, &rMEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbMouseMove = true;
}
void Window::MouseButtonDown( const MouseEvent& rMEvt )
{
- NotifyEvent aNEvt( EVENT_MOUSEBUTTONDOWN, this, &rMEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::MOUSEBUTTONDOWN, this, &rMEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbMouseButtonDown = true;
}
void Window::MouseButtonUp( const MouseEvent& rMEvt )
{
- NotifyEvent aNEvt( EVENT_MOUSEBUTTONUP, this, &rMEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::MOUSEBUTTONUP, this, &rMEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbMouseButtonUp = true;
}
diff --git a/vcl/source/window/scrwnd.cxx b/vcl/source/window/scrwnd.cxx
index 6e085b509c13..f03ce5a24fba 100644
--- a/vcl/source/window/scrwnd.cxx
+++ b/vcl/source/window/scrwnd.cxx
@@ -346,7 +346,7 @@ IMPL_LINK_NOARG(ImplWheelWindow, ImplScrollHdl)
Point aCmdMousePos( pWindow->ImplFrameToOutput( aMousePos ) );
CommandScrollData aScrollData( mnActDeltaX, mnActDeltaY );
CommandEvent aCEvt( aCmdMousePos, COMMAND_AUTOSCROLL, true, &aScrollData );
- NotifyEvent aNCmdEvt( EVENT_COMMAND, pWindow, &aCEvt );
+ NotifyEvent aNCmdEvt( MouseNotifyEvent::COMMAND, pWindow, &aCEvt );
if ( !ImplCallPreNotify( aNCmdEvt ) )
{
diff --git a/vcl/source/window/splitwin.cxx b/vcl/source/window/splitwin.cxx
index 9f82ca318864..47976fd9be45 100644
--- a/vcl/source/window/splitwin.cxx
+++ b/vcl/source/window/splitwin.cxx
@@ -2484,7 +2484,7 @@ bool SplitWindow::PreNotify( NotifyEvent& rNEvt )
{
const MouseEvent* pMouseEvt = NULL;
- if( (rNEvt.GetType() == EVENT_MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
+ if( (rNEvt.GetType() == MouseNotifyEvent::MOUSEMOVE) && (pMouseEvt = rNEvt.GetMouseEvent()) != NULL )
{
if( !pMouseEvt->GetButtons() && !pMouseEvt->IsSynthetic() && !pMouseEvt->IsModifierChanged() )
{
diff --git a/vcl/source/window/syswin.cxx b/vcl/source/window/syswin.cxx
index 6ecf711d75ac..678b7c3a59d2 100644
--- a/vcl/source/window/syswin.cxx
+++ b/vcl/source/window/syswin.cxx
@@ -114,7 +114,7 @@ SystemWindow::~SystemWindow()
bool SystemWindow::Notify( NotifyEvent& rNEvt )
{
// capture KeyEvents for menu handling
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
MenuBar* pMBar = mpMenuBar;
if ( !pMBar && ( GetType() == WINDOW_FLOATINGWINDOW ) )
@@ -133,7 +133,7 @@ bool SystemWindow::Notify( NotifyEvent& rNEvt )
bool SystemWindow::PreNotify( NotifyEvent& rNEvt )
{
// capture KeyEvents for taskpane cycling
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
if( rNEvt.GetKeyEvent()->GetKeyCode().GetCode() == KEY_F6 &&
rNEvt.GetKeyEvent()->GetKeyCode().IsMod1() &&
diff --git a/vcl/source/window/toolbox.cxx b/vcl/source/window/toolbox.cxx
index 4bb6d2bb5b1d..0610246c8ec3 100644
--- a/vcl/source/window/toolbox.cxx
+++ b/vcl/source/window/toolbox.cxx
@@ -4266,7 +4266,7 @@ void ToolBox::RequestHelp( const HelpEvent& rHEvt )
bool ToolBox::Notify( NotifyEvent& rNEvt )
{
- if ( rNEvt.GetType() == EVENT_KEYINPUT )
+ if ( rNEvt.GetType() == MouseNotifyEvent::KEYINPUT )
{
KeyEvent aKEvt = *rNEvt.GetKeyEvent();
vcl::KeyCode aKeyCode = aKEvt.GetKeyCode();
@@ -4294,7 +4294,7 @@ bool ToolBox::Notify( NotifyEvent& rNEvt )
break;
};
}
- else if( rNEvt.GetType() == EVENT_GETFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::GETFOCUS )
{
if( rNEvt.GetWindow() == this )
{
@@ -4336,7 +4336,7 @@ bool ToolBox::Notify( NotifyEvent& rNEvt )
return DockingWindow::Notify( rNEvt );
}
}
- else if( rNEvt.GetType() == EVENT_LOSEFOCUS )
+ else if( rNEvt.GetType() == MouseNotifyEvent::LOSEFOCUS )
{
// deselect
ImplHideFocus();
diff --git a/vcl/source/window/window.cxx b/vcl/source/window/window.cxx
index edb7c2e31e61..b211057922de 100644
--- a/vcl/source/window/window.cxx
+++ b/vcl/source/window/window.cxx
@@ -393,7 +393,7 @@ Window::~Window()
// announce the window is to be destroyed
{
- NotifyEvent aNEvt( EVENT_DESTROY, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::DESTROY, this );
Notify( aNEvt );
}
@@ -1915,14 +1915,14 @@ void Window::SimulateKeyPress( sal_uInt16 nKeyCode ) const
void Window::KeyInput( const KeyEvent& rKEvt )
{
- NotifyEvent aNEvt( EVENT_KEYINPUT, this, &rKEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::KEYINPUT, this, &rKEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbKeyInput = true;
}
void Window::KeyUp( const KeyEvent& rKEvt )
{
- NotifyEvent aNEvt( EVENT_KEYUP, this, &rKEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::KEYUP, this, &rKEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbKeyUp = true;
}
@@ -1949,13 +1949,13 @@ void Window::GetFocus()
return;
}
- NotifyEvent aNEvt( EVENT_GETFOCUS, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::GETFOCUS, this );
Notify( aNEvt );
}
void Window::LoseFocus()
{
- NotifyEvent aNEvt( EVENT_LOSEFOCUS, this );
+ NotifyEvent aNEvt( MouseNotifyEvent::LOSEFOCUS, this );
Notify( aNEvt );
}
@@ -2013,7 +2013,7 @@ void Window::Command( const CommandEvent& rCEvt )
{
ImplCallEventListeners( VCLEVENT_WINDOW_COMMAND, (void*)&rCEvt );
- NotifyEvent aNEvt( EVENT_COMMAND, this, &rCEvt );
+ NotifyEvent aNEvt( MouseNotifyEvent::COMMAND, this, &rCEvt );
if ( !Notify( aNEvt ) )
mpWindowImpl->mbCommand = true;
}
@@ -2679,7 +2679,7 @@ void Window::EnableInput( bool bEnable, bool bChild )
// #104827# notify parent
if ( bNotify )
{
- NotifyEvent aNEvt( bEnable ? EVENT_INPUTENABLE : EVENT_INPUTDISABLE, this );
+ NotifyEvent aNEvt( bEnable ? MouseNotifyEvent::INPUTENABLE : MouseNotifyEvent::INPUTDISABLE, this );
Notify( aNEvt );
}
}
diff --git a/vcl/source/window/winproc.cxx b/vcl/source/window/winproc.cxx
index ce5bc24cb900..6b23fc6bcd99 100644
--- a/vcl/source/window/winproc.cxx
+++ b/vcl/source/window/winproc.cxx
@@ -63,7 +63,7 @@ bool ImplCallPreNotify( NotifyEvent& rEvt )
enum ENUM_IHMFM {IHMFM_FALSE = 0, IHMFM_TRUE = 1, IHMFM_FLOAT = 2};
static sal_uInt16 ImplHandleMouseFloatMode( vcl::Window* pChild, const Point& rMousePos,
- sal_uInt16 nCode, sal_uInt16 nSVEvent,
+ sal_uInt16 nCode, MouseNotifyEvent nSVEvent,
bool bMouseLeave )
{
ImplSVData* pSVData = ImplGetSVData();
@@ -79,7 +79,7 @@ static sal_uInt16 ImplHandleMouseFloatMode( vcl::Window* pChild, const Point& rM
FloatingWindow* pFloat = pSVData->maWinData.mpFirstFloat->ImplFloatHitTest( pChild, rMousePos, nHitTest );
FloatingWindow* pLastLevelFloat;
sal_uLong nPopupFlags;
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
if ( bMouseLeave )
return IHMFM_TRUE;
@@ -96,7 +96,7 @@ static sal_uInt16 ImplHandleMouseFloatMode( vcl::Window* pChild, const Point& rM
{
if ( nCode & MOUSE_LEFT )
{
- if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if ( !pFloat )
{
@@ -144,7 +144,7 @@ static sal_uInt16 ImplHandleMouseFloatMode( vcl::Window* pChild, const Point& rM
if ( nPopupFlags & FLOATWIN_POPUPMODE_ALLMOUSEBUTTONCLOSE )
{
if ( (nPopupFlags & FLOATWIN_POPUPMODE_NOMOUSEUPCLOSE) &&
- (nSVEvent == EVENT_MOUSEBUTTONUP) )
+ (nSVEvent == MouseNotifyEvent::MOUSEBUTTONUP) )
return IHMFM_TRUE;
pLastLevelFloat->EndPopupMode( FLOATWIN_POPUPMODEEND_CANCEL | FLOATWIN_POPUPMODEEND_CLOSEALL );
if ( nPopupFlags & FLOATWIN_POPUPMODE_PATHMOUSECANCELCLICK )
@@ -220,7 +220,7 @@ static bool ImplCallCommand( vcl::Window* pChild, sal_uInt16 nEvt, void* pData =
}
CommandEvent aCEvt( aPos, nEvt, bMouse, pData );
- NotifyEvent aNCmdEvt( EVENT_COMMAND, pChild, &aCEvt );
+ NotifyEvent aNCmdEvt( MouseNotifyEvent::COMMAND, pChild, &aCEvt );
ImplDelData aDelData( pChild );
bool bPreNotify = ImplCallPreNotify( aNCmdEvt );
if ( aDelData.IsDead() )
@@ -267,7 +267,7 @@ static long ContextMenuEventLink( void* pCEvent, void* )
return 0;
}
-bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMouseLeave,
+bool ImplHandleMouseEvent( vcl::Window* pWindow, MouseNotifyEvent nSVEvent, bool bMouseLeave,
long nX, long nY, sal_uLong nMsgTime,
sal_uInt16 nCode, MouseEventModifiers nMode )
{
@@ -281,9 +281,9 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
// we need a mousemove event, before we get a mousebuttondown or a
// mousebuttonup event
- if ( (nSVEvent == EVENT_MOUSEBUTTONDOWN) || (nSVEvent == EVENT_MOUSEBUTTONUP) )
+ if ( (nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN) || (nSVEvent == MouseNotifyEvent::MOUSEBUTTONUP) )
{
- if ( (nSVEvent == EVENT_MOUSEBUTTONUP) && pSVData->maHelpData.mbExtHelpMode )
+ if ( (nSVEvent == MouseNotifyEvent::MOUSEBUTTONUP) && pSVData->maHelpData.mbExtHelpMode )
Help::EndExtHelp();
if ( pSVData->maHelpData.mpHelpWin )
{
@@ -299,7 +299,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if ( (pWinFrameData->mnLastMouseX != nX) ||
(pWinFrameData->mnLastMouseY != nY) )
{
- ImplHandleMouseEvent( pWindow, EVENT_MOUSEMOVE, false, nX, nY, nMsgTime, nCode, nMode );
+ ImplHandleMouseEvent( pWindow, MouseNotifyEvent::MOUSEMOVE, false, nX, nY, nMsgTime, nCode, nMode );
}
}
@@ -332,7 +332,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
"ImplHandleMouseEvent: TrackWin != CaptureWin" );
// AutoScrollMode
- if ( pSVData->maWinData.mpAutoScrollWin && (nSVEvent == EVENT_MOUSEBUTTONDOWN) )
+ if ( pSVData->maWinData.mpAutoScrollWin && (nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN) )
{
pSVData->maWinData.mpAutoScrollWin->EndAutoScroll();
return true;
@@ -385,7 +385,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if ( pSVData->maWinData.mpCaptureWin != pChild && (!pChild->IsEnabled() || !pChild->IsInputEnabled() || pChild->IsInModalNonRefMode() ) )
{
sal_uInt16 FloatHdl = (ImplHandleMouseFloatMode( pChild, aMousePos, nCode, nSVEvent, bMouseLeave ) & IHMFM_FLOAT);
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
ImplHandleMouseHelpRequest( pChild, aMousePos );
if( pWinFrameData->mpMouseMoveWin != pChild )
@@ -406,12 +406,12 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if(FloatHdl != IHMFM_FLOAT) // mouse-button left: don't stop the handling for the click fdo#84795
{
- if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
return true;
else
{
// Set normal MousePointer for disabled windows
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
ImplSetMousePointer( pChild );
return false;
@@ -421,13 +421,13 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
// End ExtTextInput-Mode, if the user click in the same TopLevel Window
if ( pSVData->maWinData.mpExtTextInputWin &&
- ((nSVEvent == EVENT_MOUSEBUTTONDOWN) ||
- (nSVEvent == EVENT_MOUSEBUTTONUP)) )
+ ((nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN) ||
+ (nSVEvent == MouseNotifyEvent::MOUSEBUTTONUP)) )
pSVData->maWinData.mpExtTextInputWin->EndExtTextInput( EXTTEXTINPUT_END_COMPLETE );
}
// determine mouse event data
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
// check if MouseMove belongs to same window and if the
// status did not change
@@ -539,7 +539,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
{
Point aLeaveMousePos = pMouseMoveWin->ImplFrameToOutput( aMousePos );
MouseEvent aMLeaveEvt( aLeaveMousePos, nClicks, nMode | MouseEventModifiers::LEAVEWINDOW, nCode, nCode );
- NotifyEvent aNLeaveEvt( EVENT_MOUSEMOVE, pMouseMoveWin, &aMLeaveEvt );
+ NotifyEvent aNLeaveEvt( MouseNotifyEvent::MOUSEMOVE, pMouseMoveWin, &aMLeaveEvt );
ImplDelData aDelData;
ImplDelData aDelData2;
pWinFrameData->mbInMouseMove = true;
@@ -586,7 +586,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if (pChild)
{
// mouse click
- if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
const MouseSettings& rMSettings = pChild->GetSettings().GetMouseSettings();
sal_uLong nDblClkTime = rMSettings.GetDoubleClickTime();
@@ -668,11 +668,11 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
ImplDelData aDelData;
NotifyEvent aNEvt( nSVEvent, pChild, &aMEvt );
pChild->ImplAddDel( &aDelData );
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
pChild->ImplGetFrameData()->mbInMouseMove = true;
// bring window into foreground on mouseclick
- if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if( !pSVData->maWinData.mpFirstFloat && // totop for floating windows in popup would change the focus and would close them immediately
!(pChild->ImplGetFrameWindow()->GetStyle() & WB_OWNERDRAWDECORATION) ) // ownerdrawdecorated windows must never grab focus
@@ -686,7 +686,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
else
{
bRet = false;
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
if ( pSVData->maWinData.mpTrackWin )
{
@@ -723,7 +723,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
}
}
}
- else if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ else if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if ( pSVData->maWinData.mpTrackWin &&
!(pSVData->maWinData.mnTrackFlags & STARTTRACK_MOUSEBUTTONDOWN) )
@@ -755,10 +755,10 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if ( aDelData.IsDead() )
return true;
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
pChild->ImplGetWindowImpl()->mpFrameData->mbInMouseMove = false;
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
if ( bCallHelpRequest && !pSVData->maHelpData.mbKeyboardHelp )
ImplHandleMouseHelpRequest( pChild, pChild->OutputToScreenPixel( aMEvt.GetPosPixel() ) );
@@ -766,7 +766,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
}
else if ( !bRet )
{
- if ( nSVEvent == EVENT_MOUSEBUTTONDOWN )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN )
{
if ( !pChild->ImplGetWindowImpl()->mbMouseButtonDown )
bRet = true;
@@ -780,18 +780,18 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
pChild->ImplRemoveDel( &aDelData );
- if ( nSVEvent == EVENT_MOUSEMOVE )
+ if ( nSVEvent == MouseNotifyEvent::MOUSEMOVE )
{
// set new mouse pointer
if ( !bMouseLeave )
ImplSetMousePointer( pChild );
}
- else if ( (nSVEvent == EVENT_MOUSEBUTTONDOWN) || (nSVEvent == EVENT_MOUSEBUTTONUP) )
+ else if ( (nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN) || (nSVEvent == MouseNotifyEvent::MOUSEBUTTONUP) )
{
if ( !bDrag )
{
// Command-Events
- if ( /*!bRet &&*/ (nClicks == 1) && (nSVEvent == EVENT_MOUSEBUTTONDOWN) &&
+ if ( /*!bRet &&*/ (nClicks == 1) && (nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN) &&
(nCode == MOUSE_MIDDLE) )
{
sal_uInt16 nMiddleAction = pChild->GetSettings().GetMouseSettings().GetMiddleButtonAction();
@@ -807,7 +807,7 @@ bool ImplHandleMouseEvent( vcl::Window* pWindow, sal_uInt16 nSVEvent, bool bMous
if ( (nCode == rMSettings.GetContextMenuCode()) &&
(nClicks == rMSettings.GetContextMenuClicks()) )
{
- bool bContextMenu = (nSVEvent == EVENT_MOUSEBUTTONDOWN);
+ bool bContextMenu = (nSVEvent == MouseNotifyEvent::MOUSEBUTTONDOWN);
if ( bContextMenu )
{
if( pSVData->maAppData.mpActivePopupMenu )
@@ -878,7 +878,7 @@ static vcl::Window* ImplGetKeyInputWindow( vcl::Window* pWindow )
return pChild;
}
-static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
+static bool ImplHandleKey( vcl::Window* pWindow, MouseNotifyEvent nSVEvent,
sal_uInt16 nKeyCode, sal_uInt16 nCharCode, sal_uInt16 nRepeat, bool bForward )
{
ImplSVData* pSVData = ImplGetSVData();
@@ -894,10 +894,10 @@ static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
sal_uInt16 nVCLEvent;
switch( nSVEvent )
{
- case EVENT_KEYINPUT:
+ case MouseNotifyEvent::KEYINPUT:
nVCLEvent = VCLEVENT_WINDOW_KEYINPUT;
break;
- case EVENT_KEYUP:
+ case MouseNotifyEvent::KEYUP:
nVCLEvent = VCLEVENT_WINDOW_KEYUP;
break;
default:
@@ -924,7 +924,7 @@ static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
pSVData->maAppData.mnLastInputTime = tools::Time::GetSystemTicks();
// handle tracking window
- if ( nSVEvent == EVENT_KEYINPUT )
+ if ( nSVEvent == MouseNotifyEvent::KEYINPUT )
{
#ifdef DBG_UTIL
// #105224# use Ctrl-Alt-Shift-D, Ctrl-Shift-D must be useable by app
@@ -1028,7 +1028,7 @@ static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
if ( !bKeyPreNotify && !aDelData.IsDead() )
{
- if ( nSVEvent == EVENT_KEYINPUT )
+ if ( nSVEvent == MouseNotifyEvent::KEYINPUT )
{
pChild->ImplGetWindowImpl()->mbKeyInput = false;
pChild->KeyInput( aKeyEvt );
@@ -1047,7 +1047,7 @@ static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
pChild->ImplRemoveDel( &aDelData );
- if ( nSVEvent == EVENT_KEYINPUT )
+ if ( nSVEvent == MouseNotifyEvent::KEYINPUT )
{
if ( !bKeyPreNotify && pChild->ImplGetWindowImpl()->mbKeyInput )
{
@@ -1141,7 +1141,7 @@ static bool ImplHandleKey( vcl::Window* pWindow, sal_uInt16 nSVEvent,
if ( !bPreNotify )
{
- if ( nSVEvent == EVENT_KEYINPUT )
+ if ( nSVEvent == MouseNotifyEvent::KEYINPUT )
{
pChild->ImplGetWindowImpl()->mbKeyInput = false;
pChild->KeyInput( aKEvt );
@@ -1343,7 +1343,7 @@ static bool ImplCallWheelCommand( vcl::Window* pWindow, const Point& rPos,
{
Point aCmdMousePos = pWindow->ImplFrameToOutput( rPos );
CommandEvent aCEvt( aCmdMousePos, COMMAND_WHEEL, true, pWheelData );
- NotifyEvent aNCmdEvt( EVENT_COMMAND, pWindow, &aCEvt );
+ NotifyEvent aNCmdEvt( MouseNotifyEvent::COMMAND, pWindow, &aCEvt );
ImplDelData aDelData( pWindow );
bool bPreNotify = ImplCallPreNotify( aNCmdEvt );
if ( aDelData.IsDead() )
@@ -1753,7 +1753,7 @@ IMPL_LINK_NOARG(vcl::Window, ImplAsyncFocusHdl)
static const char* pEnv = getenv("SAL_FLOATWIN_NOAPPFOCUSCLOSE");
if( !(pEnv && *pEnv) )
{
- NotifyEvent aNEvt( EVENT_LOSEFOCUS, pFocusWin );
+ NotifyEvent aNEvt( MouseNotifyEvent::LOSEFOCUS, pFocusWin );
if ( !ImplCallPreNotify( aNEvt ) )
pFocusWin->LoseFocus();
pFocusWin->ImplCallDeactivateListeners( NULL );
@@ -1956,7 +1956,7 @@ static MouseEventModifiers ImplGetMouseButtonMode( SalMouseEvent* pEvent )
inline bool ImplHandleSalMouseLeave( vcl::Window* pWindow, SalMouseEvent* pEvent )
{
- return ImplHandleMouseEvent( pWindow, EVENT_MOUSEMOVE, true,
+ return ImplHandleMouseEvent( pWindow, MouseNotifyEvent::MOUSEMOVE, true,
pEvent->mnX, pEvent->mnY,
pEvent->mnTime, pEvent->mnCode,
ImplGetMouseMoveMode( pEvent ) );
@@ -1964,7 +1964,7 @@ inline bool ImplHandleSalMouseLeave( vcl::Window* pWindow, SalMouseEvent* pEvent
inline bool ImplHandleSalMouseMove( vcl::Window* pWindow, SalMouseEvent* pEvent )
{
- return ImplHandleMouseEvent( pWindow, EVENT_MOUSEMOVE, false,
+ return ImplHandleMouseEvent( pWindow, MouseNotifyEvent::MOUSEMOVE, false,
pEvent->mnX, pEvent->mnY,
pEvent->mnTime, pEvent->mnCode,
ImplGetMouseMoveMode( pEvent ) );
@@ -1972,7 +1972,7 @@ inline bool ImplHandleSalMouseMove( vcl::Window* pWindow, SalMouseEvent* pEvent
inline bool ImplHandleSalMouseButtonDown( vcl::Window* pWindow, SalMouseEvent* pEvent )
{
- return ImplHandleMouseEvent( pWindow, EVENT_MOUSEBUTTONDOWN, false,
+ return ImplHandleMouseEvent( pWindow, MouseNotifyEvent::MOUSEBUTTONDOWN, false,
pEvent->mnX, pEvent->mnY,
pEvent->mnTime,
#ifdef MACOSX
@@ -1985,7 +1985,7 @@ inline bool ImplHandleSalMouseButtonDown( vcl::Window* pWindow, SalMouseEvent* p
inline bool ImplHandleSalMouseButtonUp( vcl::Window* pWindow, SalMouseEvent* pEvent )
{
- return ImplHandleMouseEvent( pWindow, EVENT_MOUSEBUTTONUP, false,
+ return ImplHandleMouseEvent( pWindow, MouseNotifyEvent::MOUSEBUTTONUP, false,
pEvent->mnX, pEvent->mnY,
pEvent->mnTime,
#ifdef MACOSX
@@ -2357,28 +2357,28 @@ bool ImplWindowFrameProc( vcl::Window* pWindow, SalFrame* /*pFrame*/,
case SALEVENT_KEYINPUT:
{
SalKeyEvent* pKeyEvt = (SalKeyEvent*)pEvent;
- nRet = ImplHandleKey( pWindow, EVENT_KEYINPUT,
+ nRet = ImplHandleKey( pWindow, MouseNotifyEvent::KEYINPUT,
pKeyEvt->mnCode, pKeyEvt->mnCharCode, pKeyEvt->mnRepeat, true );
}
break;
case SALEVENT_EXTERNALKEYINPUT:
{
KeyEvent* pKeyEvt = (KeyEvent*) pEvent;
- nRet = ImplHandleKey( pWindow, EVENT_KEYINPUT,
+ nRet = ImplHandleKey( pWindow, MouseNotifyEvent::KEYINPUT,
pKeyEvt->GetKeyCode().GetFullCode(), pKeyEvt->GetCharCode(), pKeyEvt->GetRepeat(), false );
}
break;
case SALEVENT_KEYUP:
{
SalKeyEvent* pKeyEvt = (SalKeyEvent*)pEvent;
- nRet = ImplHandleKey( pWindow, EVENT_KEYUP,
+ nRet = ImplHandleKey( pWindow, MouseNotifyEvent::KEYUP,
pKeyEvt->mnCode, pKeyEvt->mnCharCode, pKeyEvt->mnRepeat, true );
}
break;
case SALEVENT_EXTERNALKEYUP:
{
KeyEvent* pKeyEvt = (KeyEvent*) pEvent;
- nRet = ImplHandleKey( pWindow, EVENT_KEYUP,
+ nRet = ImplHandleKey( pWindow, MouseNotifyEvent::KEYUP,
pKeyEvt->GetKeyCode().GetFullCode(), pKeyEvt->GetCharCode(), pKeyEvt->GetRepeat(), false );
}
break;
diff --git a/vcl/win/source/window/salframe.cxx b/vcl/win/source/window/salframe.cxx
index d2fef8fc0903..c8f5f3f7b917 100644
--- a/vcl/win/source/window/salframe.cxx
+++ b/vcl/win/source/window/salframe.cxx
@@ -5214,7 +5214,7 @@ static boolean ImplHandleAppCommand( HWND hWnd, LPARAM lParam )
{
const Point aPoint;
CommandEvent aCEvt( aPoint, COMMAND_MEDIA, FALSE, &nCommand );
- NotifyEvent aNCmdEvt( EVENT_COMMAND, pWindow, &aCEvt );
+ NotifyEvent aNCmdEvt( MouseNotifyEvent::COMMAND, pWindow, &aCEvt );
if ( !ImplCallPreNotify( aNCmdEvt ) )
{