Window::Notify should return bool
Change-Id: I72081b1022582c8b6f95a611e21d9c78f7581efe
This commit is contained in:
@@ -130,15 +130,15 @@ namespace
|
||||
virtual void DataChanged(const DataChangedEvent& rDCEvt);
|
||||
public:
|
||||
OTablePreviewWindow( Window* pParent, WinBits nStyle = 0 );
|
||||
virtual long Notify( NotifyEvent& rNEvt );
|
||||
virtual bool Notify( NotifyEvent& rNEvt );
|
||||
};
|
||||
OTablePreviewWindow::OTablePreviewWindow(Window* pParent, WinBits nStyle) : Window( pParent, nStyle)
|
||||
{
|
||||
ImplInitSettings( sal_True, sal_True, sal_True );
|
||||
}
|
||||
long OTablePreviewWindow::Notify( NotifyEvent& rNEvt )
|
||||
bool OTablePreviewWindow::Notify( NotifyEvent& rNEvt )
|
||||
{
|
||||
long nRet = Window::Notify( rNEvt );
|
||||
bool nRet = Window::Notify( rNEvt );
|
||||
if ( rNEvt.GetType() == EVENT_INPUTENABLE && IsInputEnabled() )
|
||||
PostUserEvent( LINK( this, OTablePreviewWindow, OnDisableInput) );
|
||||
return nRet;
|
||||
|
@@ -34,7 +34,7 @@ class LimitBoxImpl: public LimitBox
|
||||
LimitBoxImpl( Window* pParent, LimitBoxController* pCtrl );
|
||||
virtual ~LimitBoxImpl();
|
||||
|
||||
virtual long Notify( NotifyEvent& rNEvt );
|
||||
virtual bool Notify( NotifyEvent& rNEvt );
|
||||
|
||||
private:
|
||||
LimitBoxController* m_pControl;
|
||||
@@ -50,9 +50,9 @@ LimitBoxImpl::~LimitBoxImpl()
|
||||
{
|
||||
}
|
||||
|
||||
long LimitBoxImpl::Notify( NotifyEvent& rNEvt )
|
||||
bool LimitBoxImpl::Notify( NotifyEvent& rNEvt )
|
||||
{
|
||||
long nHandled = 0;
|
||||
bool nHandled = false;
|
||||
switch ( rNEvt.GetType() )
|
||||
{
|
||||
case EVENT_LOSEFOCUS:
|
||||
@@ -76,7 +76,7 @@ long LimitBoxImpl::Notify( NotifyEvent& rNEvt )
|
||||
case KEY_RETURN:
|
||||
{
|
||||
GrabFocusToDocument();
|
||||
nHandled = 1;
|
||||
nHandled = true;
|
||||
break;
|
||||
}
|
||||
case KEY_TAB:
|
||||
@@ -88,7 +88,7 @@ long LimitBoxImpl::Notify( NotifyEvent& rNEvt )
|
||||
break;
|
||||
}
|
||||
}
|
||||
return nHandled ? nHandled : LimitBox::Notify( rNEvt );
|
||||
return nHandled || LimitBox::Notify( rNEvt );
|
||||
}
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user