[Libreoffice-commits] .: Branch 'libreoffice-3-6' - sfx2/source

Fridrich Strba fridrich at kemper.freedesktop.org
Mon Jul 16 06:35:26 PDT 2012


 sfx2/source/appl/shutdowniconw32.cxx |    7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

New commits:
commit dd57301eef0d99943672da7fc3d453ee3db4ad6e
Author: Andras Timar <atimar at suse.com>
Date:   Mon Jul 16 15:03:46 2012 +0200

    fdo#52143 use Unicode functions for QuickStarter tooltip
    
    Change-Id: Ic9c7ed84925ea5b4ce324a98a1089102dcda24b8
    Signed-off-by: Fridrich Å trba <fridrich.strba at bluewin.ch>

diff --git a/sfx2/source/appl/shutdowniconw32.cxx b/sfx2/source/appl/shutdowniconw32.cxx
index 0d3b86c..28f783b 100644
--- a/sfx2/source/appl/shutdowniconw32.cxx
+++ b/sfx2/source/appl/shutdowniconw32.cxx
@@ -284,13 +284,12 @@ static void addTaskbarIcon( HWND hWnd )
         strTip = ShutdownIcon::getInstance()->GetResString( STR_QUICKSTART_TIP );
 
     // add taskbar icon
-    NOTIFYICONDATAA nid;
+    NOTIFYICONDATAW nid;
     nid.hIcon = (HICON)LoadImageA( GetModuleHandle( NULL ), MAKEINTRESOURCE( ICON_LO_DEFAULT ),
         IMAGE_ICON, GetSystemMetrics( SM_CXSMICON ), GetSystemMetrics( SM_CYSMICON ),
         LR_DEFAULTCOLOR | LR_SHARED );
 
-    // better use unicode wrapper here ?
-    strncpy( nid.szTip, ( OUStringToOString(strTip, osl_getThreadTextEncoding()).getStr() ), 64 );
+    wcsncpy( nid.szTip, strTip.getStr(), 64 );
 
     nid.cbSize              = sizeof(nid);
     nid.hWnd                = hWnd;
@@ -298,7 +297,7 @@ static void addTaskbarIcon( HWND hWnd )
     nid.uCallbackMessage    = SFX_TASKBAR_NOTIFICATION;
     nid.uFlags              = NIF_MESSAGE|NIF_TIP|NIF_ICON;
 
-    Shell_NotifyIconA(NIM_ADD, &nid);
+    Shell_NotifyIconW(NIM_ADD, &nid);
 }
 
 // -------------------------------


More information about the Libreoffice-commits mailing list