diff options
author | Mathias Bauer <mba@openoffice.org> | 2010-07-13 14:38:37 +0200 |
---|---|---|
committer | Mathias Bauer <mba@openoffice.org> | 2010-07-13 14:38:37 +0200 |
commit | ca851f72310bf83c0e6e7cb98fd58e6271fa0f01 (patch) | |
tree | 7f1d1b1461d41b823a7a91464b1874c21b25d2a3 /vcl/source/app | |
parent | 22e9afcab567030e0b1d029400dd85851b2d86e3 (diff) | |
parent | be588658ea127a6a05390435126f1d739a477b58 (diff) |
CWS changehid: resync to m84
Diffstat (limited to 'vcl/source/app')
-rw-r--r-- | vcl/source/app/help.cxx | 30 | ||||
-rw-r--r-- | vcl/source/app/svapp.cxx | 5 |
2 files changed, 23 insertions, 12 deletions
diff --git a/vcl/source/app/help.cxx b/vcl/source/app/help.cxx index 33209de44950..b09e7746a886 100644 --- a/vcl/source/app/help.cxx +++ b/vcl/source/app/help.cxx @@ -747,18 +747,26 @@ void ImplSetHelpWindowPos( Window* pHelpWin, USHORT nHelpWinStyle, USHORT nStyle else if ( ( aPos.Y() + aSz.Height() ) > aScreenRect.Bottom() ) aPos.Y() = aScreenRect.Bottom() - aSz.Height(); - // the popup must not appear under the mouse - // otherwise it would directly be closed due to a focus change... - Rectangle aHelpRect( aPos, aSz ); - if( aHelpRect.IsInside( mPos ) ) + if( ! (nStyle & QUICKHELP_NOEVADEPOINTER) ) { - Point delta(2,2); - Point pSize( aSz.Width(), aSz.Height() ); - Point pTest( mPos - pSize - delta ); - if( pTest.X() > aScreenRect.Left() && pTest.Y() > aScreenRect.Top() ) - aPos = pTest; - else - aPos = mPos + delta; + /* the remark below should be obsolete by now as the helpwindow should + not be focusable, leaving it as a hint. However it is sensible in most + conditions to evade the mouse pointer so the content window is fully visible. + + // the popup must not appear under the mouse + // otherwise it would directly be closed due to a focus change... + */ + Rectangle aHelpRect( aPos, aSz ); + if( aHelpRect.IsInside( mPos ) ) + { + Point delta(2,2); + Point pSize( aSz.Width(), aSz.Height() ); + Point pTest( mPos - pSize - delta ); + if( pTest.X() > aScreenRect.Left() && pTest.Y() > aScreenRect.Top() ) + aPos = pTest; + else + aPos = mPos + delta; + } } Window* pWindow = pHelpWin->GetParent()->ImplGetFrameWindow(); diff --git a/vcl/source/app/svapp.cxx b/vcl/source/app/svapp.cxx index 7cec6867e0a3..e503172eb2c6 100644 --- a/vcl/source/app/svapp.cxx +++ b/vcl/source/app/svapp.cxx @@ -1975,11 +1975,14 @@ BOOL Application::IsHeadlessModeEnabled() void Application::ShowNativeErrorBox(const String& sTitle , const String& sMessage) { - ImplGetSalSystem()->ShowNativeMessageBox ( + int btn = ImplGetSalSystem()->ShowNativeMessageBox ( sTitle, sMessage, SALSYSTEM_SHOWNATIVEMSGBOX_BTNCOMBI_OK, SALSYSTEM_SHOWNATIVEMSGBOX_BTN_OK); + if (btn != SALSYSTEM_SHOWNATIVEMSGBOX_BTN_OK) { + OSL_TRACE("ShowNativeMessageBox returned %d\n", btn); + } } // ----------------------------------------------------------------------- |