You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
libreoffice/workspace.cmcfixes79.patch

380 lines
17 KiB

diff -r 5893d50a0b8c desktop/source/app/app.cxx
--- a/desktop/source/app/app.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/desktop/source/app/app.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -2129,23 +2129,8 @@
hMouseSettings.SetFollow( aAppearanceCfg.IsMenuMouseFollow() ? (nFollow|MOUSE_FOLLOW_MENU) : (nFollow&~MOUSE_FOLLOW_MENU));
rSettings.SetMouseSettings(hMouseSettings);
- BOOL bUseImagesInMenus = hStyleSettings.GetUseImagesInMenus();
-
SvtMenuOptions aMenuOpt;
- nGet = aMenuOpt.GetMenuIconsState();
- switch ( nGet )
- {
- case 0:
- bUseImagesInMenus = FALSE;
- break;
- case 1:
- bUseImagesInMenus = TRUE;
- break;
- case 2:
- default:
- break;
- }
- hStyleSettings.SetUseImagesInMenus(bUseImagesInMenus);
+ hStyleSettings.SetUseImagesInMenus(aMenuOpt.GetMenuIconsState());
sal_uInt16 nTabStyle = hStyleSettings.GetTabControlStyle();
nTabStyle &= ~STYLE_TABCONTROL_SINGLELINE;
diff -r 5893d50a0b8c framework/source/classes/menumanager.cxx
--- a/framework/source/classes/menumanager.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/framework/source/classes/menumanager.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -169,11 +169,13 @@
{
USHORT nItemId = FillItemCommand(aItemCommand,pMenu, i );
bool bShowMenuImages( m_bShowMenuImages );
- MenuItemBits nBits = pMenu->GetItemBits( nItemId );
- // overwrite the default?
- if ( nBits )
+
+ // overwrite the show icons on menu option?
+ if (!bShowMenuImages)
+ {
+ MenuItemBits nBits = pMenu->GetItemBits( nItemId );
bShowMenuImages = ( ( nBits & MIB_ICON ) == MIB_ICON );
-
+ }
PopupMenu* pPopupMenu = pMenu->GetPopupMenu( nItemId );
if ( pPopupMenu )
@@ -1137,10 +1139,12 @@
if ( _pMenu->GetItemType( nPos ) != MENUITEM_SEPARATOR )
{
bool bTmpShowMenuImages( bShowMenuImages );
- MenuItemBits nBits = _pMenu->GetItemBits( nId );
- // overwrite the default?
- if ( nBits )
+ // overwrite the show icons on menu option?
+ if (!bTmpShowMenuImages)
+ {
+ MenuItemBits nBits = _pMenu->GetItemBits( nId );
bTmpShowMenuImages = ( ( nBits & MIB_ICON ) == MIB_ICON );
+ }
if ( bTmpShowMenuImages )
{
diff -r 5893d50a0b8c framework/source/uielement/menubarmanager.cxx
--- a/framework/source/uielement/menubarmanager.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/framework/source/uielement/menubarmanager.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -1331,10 +1331,12 @@
Reference< XStatusListener > xStatusListener;
PopupMenu* pPopup = pMenu->GetPopupMenu( nItemId );
bool bItemShowMenuImages = m_bShowMenuImages;
- MenuItemBits nBits = pMenu->GetItemBits( nItemId );
// overwrite the show icons on menu option?
- if ( nBits )
+ if (!bItemShowMenuImages)
+ {
+ MenuItemBits nBits = pMenu->GetItemBits( nItemId );
bItemShowMenuImages = ( ( nBits & MIB_ICON ) == MIB_ICON );
+ }
if ( pPopup )
{
// Retrieve module identifier from Help Command entry
diff -r 5893d50a0b8c officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu
--- a/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu Wed Sep 08 15:25:35 2010 +0100
+++ b/officecfg/registry/data/org/openoffice/Office/UI/CalcCommands.xcu Mon Sep 13 15:13:31 2010 +0100
@@ -41,6 +41,14 @@
<value xml:lang="en-US">~Trace Dependents</value>
</prop>
</node>
+ <node oor:name=".uno:SinglePane" oor:op="replace">
+ <prop oor:name="Label" oor:type="xs:string">
+ <value xml:lang="en-US">~Normal Pane</value>
+ </prop>
+ <prop oor:name="ContextLabel" oor:type="xs:string">
+ <value xml:lang="en-US">~Normal</value>
+ </prop>
+ </node>
<node oor:name=".uno:SplitWindow" oor:op="replace">
<prop oor:name="Label" oor:type="xs:string">
<value xml:lang="en-US">~Split Window</value>
diff -r 5893d50a0b8c sd/uiconfig/simpress/menubar/menubar.xml
--- a/sd/uiconfig/simpress/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sd/uiconfig/simpress/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -79,14 +79,14 @@
<menu:menuitem menu:id=".uno:NormalMultiPaneGUI" menu:style="radio"/>
<menu:menuitem menu:id=".uno:OutlineMode" menu:style="radio"/>
<menu:menuitem menu:id=".uno:DiaMode" menu:style="radio"/>
- <menu:menuitem menu:id=".uno:Presentation"/>
+ <menu:menuitem menu:id=".uno:Presentation" menu:style="radio"/>
<menu:menuitem menu:id=".uno:NotesMode" menu:style="radio"/>
<menu:menuitem menu:id=".uno:HandoutMode" menu:style="radio"/>
<menu:menuseparator/>
<menu:menu menu:id=".uno:MasterPageMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:SlideMasterPage"/>
- <menu:menuitem menu:id=".uno:NotesMasterPage"/>
+ <menu:menuitem menu:id=".uno:SlideMasterPage" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:NotesMasterPage" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:MasterLayouts"/>
</menu:menupopup>
diff -r 5893d50a0b8c svtools/source/config/menuoptions.cxx
--- a/svtools/source/config/menuoptions.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/svtools/source/config/menuoptions.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -190,9 +190,9 @@
Commit();
}
- void SetMenuIconsState ( sal_Int16 bState )
+ void SetMenuIconsState ( sal_Int16 nState )
{
- m_nMenuIcons = bState;
+ m_nMenuIcons = nState;
SetModified();
for ( USHORT n=0; n<aList.Count(); n++ )
aList.GetObject(n)->Call( this );
@@ -318,7 +318,7 @@
sal_Bool bMenuIcons = sal_True;
sal_Bool bSystemMenuIcons = sal_True;
if (m_nMenuIcons == 2)
- bMenuIcons = (sal_Bool)(Application::GetSettings().GetStyleSettings().GetUseImagesInMenus());
+ bMenuIcons = (sal_Bool)(Application::GetSettings().GetStyleSettings().GetPreferredUseImagesInMenus());
else
{
bSystemMenuIcons = sal_False;
@@ -342,12 +342,12 @@
else if( seqPropertyNames[nProperty] == PROPERTYNAME_SHOWICONSINMENUES )
{
DBG_ASSERT(!(seqValues[nProperty].getValueTypeClass()!=TypeClass_BOOLEAN), "SvtMenuOptions_Impl::SvtMenuOptions_Impl()\nWho has changed the value type of \"Office.Common\\View\\Menu\\ShowIconsInMenues\"?" );
- bMenuSettingsChanged = seqValues[nProperty] >>= bMenuIcons;
+ bMenuSettingsChanged |= seqValues[nProperty] >>= bMenuIcons;
}
else if( seqPropertyNames[nProperty] == PROPERTYNAME_SYSTEMICONSINMENUES )
{
DBG_ASSERT(!(seqValues[nProperty].getValueTypeClass()!=TypeClass_BOOLEAN), "SvtMenuOptions_Impl::SvtMenuOptions_Impl()\nWho has changed the value type of \"Office.Common\\View\\Menu\\IsSystemIconsInMenus\"?" );
- bMenuSettingsChanged = seqValues[nProperty] >>= bSystemMenuIcons;
+ bMenuSettingsChanged |= seqValues[nProperty] >>= bSystemMenuIcons;
}
#if OSL_DEBUG_LEVEL > 1
diff -r 5893d50a0b8c sw/uiconfig/sglobal/menubar/menubar.xml
--- a/sw/uiconfig/sglobal/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/sglobal/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -103,8 +103,8 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c sw/uiconfig/sweb/menubar/menubar.xml
--- a/sw/uiconfig/sweb/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/sweb/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -75,9 +75,9 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
- <menu:menuitem menu:id=".uno:SourceView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:SourceView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c sw/uiconfig/swform/menubar/menubar.xml
--- a/sw/uiconfig/swform/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/swform/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -103,8 +103,8 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c sw/uiconfig/swreport/menubar/menubar.xml
--- a/sw/uiconfig/swreport/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/swreport/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -103,8 +103,8 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c sw/uiconfig/swriter/menubar/menubar.xml
--- a/sw/uiconfig/swriter/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/swriter/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -106,8 +106,8 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c sw/uiconfig/swxform/menubar/menubar.xml
--- a/sw/uiconfig/swxform/menubar/menubar.xml Wed Sep 08 15:25:35 2010 +0100
+++ b/sw/uiconfig/swxform/menubar/menubar.xml Mon Sep 13 15:13:31 2010 +0100
@@ -104,8 +104,8 @@
</menu:menu>
<menu:menu menu:id=".uno:ViewMenu">
<menu:menupopup>
- <menu:menuitem menu:id=".uno:PrintLayout"/>
- <menu:menuitem menu:id=".uno:BrowseView"/>
+ <menu:menuitem menu:id=".uno:PrintLayout" menu:style="radio"/>
+ <menu:menuitem menu:id=".uno:BrowseView" menu:style="radio"/>
<menu:menuseparator/>
<menu:menuitem menu:id=".uno:AvailableToolbars"/>
<menu:menuitem menu:id=".uno:StatusBarVisible"/>
diff -r 5893d50a0b8c vcl/aqua/source/window/salframe.cxx
--- a/vcl/aqua/source/window/salframe.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/vcl/aqua/source/window/salframe.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -1266,7 +1266,7 @@
aStyleSettings.SetScrollBarSize( static_cast<long int>([NSScroller scrollerWidth]) );
// images in menus false for MacOSX
- aStyleSettings.SetUseImagesInMenus( false );
+ aStyleSettings.SetPreferredUseImagesInMenus( false );
rSettings.SetStyleSettings( aStyleSettings );
diff -r 5893d50a0b8c vcl/inc/vcl/settings.hxx
--- a/vcl/inc/vcl/settings.hxx Wed Sep 08 15:25:35 2010 +0100
+++ b/vcl/inc/vcl/settings.hxx Mon Sep 13 15:13:31 2010 +0100
@@ -431,6 +431,7 @@
USHORT mnUseSystemUIFonts;
USHORT mnAutoMnemonic;
USHORT mnUseImagesInMenus;
+ BOOL mbPreferredUseImagesInMenus;
ULONG mnUseFlatBorders;
long mnMinThumbSize;
ULONG mnSymbolsStyle;
@@ -525,6 +526,10 @@
#define STYLE_SYMBOLS_CLASSIC ((ULONG)7)
#define STYLE_SYMBOLS_THEMES_MAX ((ULONG)8)
+#define STYLE_MENUIMAGES_OFF ((USHORT)0)
+#define STYLE_MENUIMAGES_ON ((USHORT)1)
+#define STYLE_MENUIMAGES_AUTO ((USHORT)2)
+
#define STYLE_CURSOR_NOBLINKTIME ((ULONG)0xFFFFFFFF)
class VCL_DLLPUBLIC StyleSettings
@@ -746,10 +751,16 @@
{ CopyData(); mpData->mnUseFlatMenues = bUseFlatMenues; }
BOOL GetUseFlatMenues() const
{ return (BOOL) mpData->mnUseFlatMenues; }
+
void SetUseImagesInMenus( BOOL bUseImagesInMenus )
{ CopyData(); mpData->mnUseImagesInMenus = bUseImagesInMenus; }
- BOOL GetUseImagesInMenus() const
- { return (BOOL) mpData->mnUseImagesInMenus; }
+ BOOL GetUseImagesInMenus() const;
+
+ void SetPreferredUseImagesInMenus( BOOL bPreferredUseImagesInMenus )
+ { CopyData(); mpData->mbPreferredUseImagesInMenus = bPreferredUseImagesInMenus; }
+ BOOL GetPreferredUseImagesInMenus() const
+ { return mpData->mbPreferredUseImagesInMenus; }
+
void SetSkipDisabledInMenus( BOOL bSkipDisabledInMenus )
{ CopyData(); mpData->mnSkipDisabledInMenus = bSkipDisabledInMenus; }
BOOL GetSkipDisabledInMenus() const
diff -r 5893d50a0b8c vcl/source/app/settings.cxx
--- a/vcl/source/app/settings.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/vcl/source/app/settings.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -435,6 +435,7 @@
mnAutoMnemonic = 1;
mnToolbarIconSize = STYLE_TOOLBAR_ICONSIZE_UNKNOWN;
mnSymbolsStyle = STYLE_SYMBOLS_AUTO;
+ mnUseImagesInMenus = STYLE_MENUIMAGES_AUTO;
mnPreferredSymbolsStyle = STYLE_SYMBOLS_AUTO;
mpFontOptions = NULL;
@@ -539,6 +540,7 @@
mnUseFlatMenues = rData.mnUseFlatMenues;
mnAutoMnemonic = rData.mnAutoMnemonic;
mnUseImagesInMenus = rData.mnUseImagesInMenus;
+ mbPreferredUseImagesInMenus = rData.mbPreferredUseImagesInMenus;
mnSkipDisabledInMenus = rData.mnSkipDisabledInMenus;
mnToolbarIconSize = rData.mnToolbarIconSize;
mnSymbolsStyle = rData.mnSymbolsStyle;
@@ -632,7 +634,7 @@
mnUseSystemUIFonts = 1;
mnUseFlatBorders = 0;
mnUseFlatMenues = 0;
- mnUseImagesInMenus = (USHORT)TRUE;
+ mbPreferredUseImagesInMenus = TRUE;
mnSkipDisabledInMenus = (USHORT)FALSE;
Gradient aGrad( GRADIENT_LINEAR, DEFAULT_WORKSPACE_GRADIENT_START_COLOR, DEFAULT_WORKSPACE_GRADIENT_END_COLOR );
@@ -866,6 +868,19 @@
// -----------------------------------------------------------------------
+BOOL StyleSettings::GetUseImagesInMenus() const
+{
+ // icon mode selected in Tools -> Options... -> OpenOffice.org -> View
+ USHORT nStyle = mpData->mnUseImagesInMenus;
+
+ if ( nStyle == STYLE_MENUIMAGES_AUTO )
+ return GetPreferredUseImagesInMenus();
+
+ return (BOOL)nStyle;
+}
+
+// -----------------------------------------------------------------------
+
void StyleSettings::SetStandardStyles()
{
CopyData();
@@ -1104,6 +1119,7 @@
(mpData->maFieldFont == rSet.mpData->maFieldFont) &&
(mpData->maIconFont == rSet.mpData->maIconFont) &&
(mpData->mnUseImagesInMenus == rSet.mpData->mnUseImagesInMenus) &&
+ (mpData->mbPreferredUseImagesInMenus == rSet.mpData->mbPreferredUseImagesInMenus) &&
(mpData->mnSkipDisabledInMenus == rSet.mpData->mnSkipDisabledInMenus) &&
(mpData->maFontColor == rSet.mpData->maFontColor ))
return TRUE;
diff -r 5893d50a0b8c vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx
--- a/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx Wed Sep 08 15:25:35 2010 +0100
+++ b/vcl/unx/gtk/gdi/salnativewidgets-gtk.cxx Mon Sep 13 15:13:31 2010 +0100
@@ -3552,7 +3552,7 @@
gboolean showmenuicons = true;
pSettings = gtk_widget_get_settings( gWidgetData[m_nScreen].gImageMenuItem );
g_object_get( pSettings, "gtk-menu-images", &showmenuicons, (char *)NULL );
- aStyleSet.SetUseImagesInMenus( showmenuicons );
+ aStyleSet.SetPreferredUseImagesInMenus( showmenuicons );
// set scrollbar settings
gint slider_width = 14;
--- a/idlc/source/preproc/tokens.c 2010-09-08 13:23:54.000000000 +0100
+++ b/idlc/source/preproc/tokens.c 2010-09-08 13:24:20.000000000 +0100
@@ -477,7 +477,7 @@
if (write(1, wbuf, OBS) != OBS)
error(ERROR, "short write!");
if (wbp > &wbuf[OBS])
- memcpy(wbuf, wbuf + OBS, wbp - &wbuf[OBS]);
+ memmove(wbuf, wbuf + OBS, wbp - &wbuf[OBS]);
wbp -= OBS;
}
}