diff options
38 files changed, 290 insertions, 100 deletions
diff --git a/basic/source/app/app.cxx b/basic/source/app/app.cxx index aeeb46acc4d7..558a01353fbd 100644 --- a/basic/source/app/app.cxx +++ b/basic/source/app/app.cxx @@ -243,8 +243,8 @@ int BasicApp::Main( ) try { + // this line is not ( afaics ) necessary ( remove from master ) uno::Reference< XContentProviderManager > xUcb = InitializeUCB(); - { DirEntry aIniPath( Config::GetConfigName( Config::GetDefDirectory(), CUniString("testtool") ) ); if ( !aIniPath.Exists() ) diff --git a/basic/source/runtime/iosys.cxx b/basic/source/runtime/iosys.cxx index f4dc783ee878..b71558b0fb7e 100644 --- a/basic/source/runtime/iosys.cxx +++ b/basic/source/runtime/iosys.cxx @@ -570,7 +570,6 @@ void UCBStream::SetSize( sal_uIntPtr nSize ) SetError( ERRCODE_IO_GENERAL ); } - // Oeffnen eines Streams SbError SbiStream::Open ( short nCh, const ByteString& rName, short nStrmMode, short nFlags, short nL ) diff --git a/configmgr/source/components.cxx b/configmgr/source/components.cxx index 3896fbee4cdc..8760946020f5 100644 --- a/configmgr/source/components.cxx +++ b/configmgr/source/components.cxx @@ -510,12 +510,16 @@ css::beans::Optional< css::uno::Any > Components::getExternalValue( return value; } +int tempHACK = 0; + Components::Components( css::uno::Reference< css::uno::XComponentContext > const & context): context_(context) { lock_ = lock(); + tempHACK = 1; + OSL_ASSERT(context.is()); RTL_LOGFILE_TRACE_AUTHOR("configmgr", "sb", "begin parsing"); parseXcsXcuLayer( @@ -594,6 +598,7 @@ Components::Components( Components::~Components() { flushModifications(); + tempHACK = 0; } void Components::parseFileLeniently( diff --git a/configmgr/source/rootaccess.cxx b/configmgr/source/rootaccess.cxx index ef5982e3a56d..90e5675b35a3 100644 --- a/configmgr/source/rootaccess.cxx +++ b/configmgr/source/rootaccess.cxx @@ -284,6 +284,8 @@ void RootAccess::removeChangesListener( } } +extern int tempHACK; + void RootAccess::commitChanges() throw (css::lang::WrappedTargetException, css::uno::RuntimeException) { @@ -291,6 +293,13 @@ void RootAccess::commitChanges() Broadcaster bc; { osl::MutexGuard g(*lock_); + + // OSL_ENSURE(tempHACK, "fucktastic!, seriously busted lifecycles\n"); + if (!tempHACK) + { + return; + } + checkLocalizedPropertyAccess(); int finalizedLayer; Modifications globalMods; diff --git a/desktop/win32/source/setup/Resource.h b/desktop/win32/source/setup/Resource.h index 600056d0a8ee..600056d0a8ee 100755..100644 --- a/desktop/win32/source/setup/Resource.h +++ b/desktop/win32/source/setup/Resource.h diff --git a/desktop/win32/source/setup/makefile.mk b/desktop/win32/source/setup/makefile.mk index f0c6e0e955fd..f0c6e0e955fd 100755..100644 --- a/desktop/win32/source/setup/makefile.mk +++ b/desktop/win32/source/setup/makefile.mk diff --git a/desktop/win32/source/setup/rcfooter.txt b/desktop/win32/source/setup/rcfooter.txt index 3237729437f5..3237729437f5 100755..100644 --- a/desktop/win32/source/setup/rcfooter.txt +++ b/desktop/win32/source/setup/rcfooter.txt diff --git a/desktop/win32/source/setup/rcheader.txt b/desktop/win32/source/setup/rcheader.txt index 9a59ad7f6477..9a59ad7f6477 100755..100644 --- a/desktop/win32/source/setup/rcheader.txt +++ b/desktop/win32/source/setup/rcheader.txt diff --git a/desktop/win32/source/setup/rctmpl.txt b/desktop/win32/source/setup/rctmpl.txt index 59f454f70c16..59f454f70c16 100755..100644 --- a/desktop/win32/source/setup/rctmpl.txt +++ b/desktop/win32/source/setup/rctmpl.txt diff --git a/desktop/win32/source/setup/setup.cpp b/desktop/win32/source/setup/setup.cpp index 35335f9c5435..52746837646c 100755..100644 --- a/desktop/win32/source/setup/setup.cpp +++ b/desktop/win32/source/setup/setup.cpp @@ -87,8 +87,8 @@ #define RUNTIME_X64_NAME TEXT( "redist\\vcredist_x64.exe" ) #define RUNTIME_X86_NAME TEXT( "redist\\vcredist_x86.exe" ) -#define PRODUCTCODE_X86 TEXT( "{E503B4BF-F7BB-3D5F-8BC8-F694B1CFF942}" ) -#define PRODUCTCODE_X64 TEXT( "{350AA351-21FA-3270-8B7A-835434E766AD}" ) +#define PRODUCTCODE_X86 TEXT( "{1F1C2DFC-2D24-3E06-BCB8-725134ADF989}" ) +#define PRODUCTCODE_X64 TEXT( "{4B6C7001-C7D6-3710-913E-5BC23FCE91E6}" ) #define MSIAPI_DllGetVersion "DllGetVersion" #define ADVAPI32API_CheckTokenMembership "CheckTokenMembership" @@ -835,10 +835,10 @@ boolean SetupAppX::LaunchInstaller( LPCTSTR pParam ) PROCESS_INFORMATION aPI; Log( TEXT( " Will install using <%s>\r\n" ), sMsiPath ); - Log( TEXT( " Prameters are: %s\r\n" ), pParam ); + Log( TEXT( " Parameters are: %s\r\n" ), pParam ); OutputDebugStringFormat( TEXT( " Will install using <%s>\r\n" ), sMsiPath ); - OutputDebugStringFormat( TEXT( " Prameters are: %s\r\n" ), pParam ); + OutputDebugStringFormat( TEXT( " Parameters are: %s\r\n" ), pParam ); ZeroMemory( (void*)&aPI, sizeof( PROCESS_INFORMATION ) ); ZeroMemory( (void*)&aSUI, sizeof( STARTUPINFO ) ); diff --git a/desktop/win32/source/setup/setup.ulf b/desktop/win32/source/setup/setup.ulf index 85d43f43aa55..85d43f43aa55 100755..100644 --- a/desktop/win32/source/setup/setup.ulf +++ b/desktop/win32/source/setup/setup.ulf diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index 5185dcd12ad0..64591310d7dd 100644 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -113,7 +113,7 @@ SV_IMPL_VARARR( EECharAttribArray, EECharAttrib ); static SfxItemPool* pGlobalPool=0; -// ---------------------------------------------------------------------- +// ---------------------------------------------------------------------- // EditEngine // ---------------------------------------------------------------------- EditEngine::EditEngine( SfxItemPool* pItemPool ) diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx index 16738e029819..b43444d4efda 100644 --- a/editeng/source/editeng/impedit3.cxx +++ b/editeng/source/editeng/impedit3.cxx @@ -934,7 +934,7 @@ sal_Bool ImpEditEngine::CreateLines( sal_uInt16 nPara, sal_uInt32 nStartPosY ) long nCurPos = nTmpWidth+nStartX; // consider scaling if ( aStatus.DoStretch() && ( nStretchX != 100 ) ) - nCurPos = nCurPos*100/nStretchX; + nCurPos = nCurPos*100/std::max(static_cast<sal_Int32>(nStretchX), static_cast<sal_Int32>(1)); short nAllSpaceBeforeText = static_cast< short >(rLRItem.GetTxtLeft()/* + rLRItem.GetTxtLeft()*/ + nSpaceBeforeAndMinLabelWidth); aCurrentTab.aTabStop = pNode->GetContentAttribs().FindTabStop( nCurPos - nAllSpaceBeforeText /*rLRItem.GetTxtLeft()*/, aEditDoc.GetDefTab() ); @@ -1308,6 +1308,13 @@ sal_Bool ImpEditEngine::CreateLines( sal_uInt16 nPara, sal_uInt32 nStartPosY ) pLine->SetHeight( nMinHeight, nTxtHeight ); } } + else if ( rLSItem.GetLineSpaceRule() == SVX_LINE_SPACE_FIX ) + { + sal_uInt16 nFixHeight = GetYValue( rLSItem.GetLineHeight() ); + sal_uInt16 nTxtHeight = pLine->GetHeight(); + pLine->SetMaxAscent( (sal_uInt16)(pLine->GetMaxAscent() + ( nFixHeight - nTxtHeight ) ) ); + pLine->SetHeight( nFixHeight, nTxtHeight ); + } else if ( rLSItem.GetInterLineSpaceRule() == SVX_INTER_LINE_SPACE_PROP ) { if ( nPara || IsFixedCellHeight() || pLine->GetStartPortion() ) // Not the very first line @@ -1636,6 +1643,14 @@ void ImpEditEngine::CreateAndInsertEmptyLine( ParaPortion* pParaPortion, sal_uIn pTmpLine->SetHeight( nMinHeight, nTxtHeight ); } } + else if ( rLSItem.GetLineSpaceRule() == SVX_LINE_SPACE_FIX ) + { + sal_uInt16 nFixHeight = rLSItem.GetLineHeight(); + sal_uInt16 nTxtHeight = pTmpLine->GetHeight(); + + pTmpLine->SetMaxAscent( (sal_uInt16)(pTmpLine->GetMaxAscent() + ( nFixHeight - nTxtHeight ) ) ); + pTmpLine->SetHeight( nFixHeight, nTxtHeight ); + } else if ( rLSItem.GetInterLineSpaceRule() == SVX_INTER_LINE_SPACE_PROP ) { sal_uInt16 nPara = GetParaPortions().GetPos( pParaPortion ); diff --git a/formula/source/ui/dlg/formula.cxx b/formula/source/ui/dlg/formula.cxx index ab266ddd9b7e..5e695de116fc 100644 --- a/formula/source/ui/dlg/formula.cxx +++ b/formula/source/ui/dlg/formula.cxx @@ -669,7 +669,11 @@ void FormulaDlg_Impl::MakeTree(IStructHelper* _pTree,SvLBoxEntry* pParent,Formul // #i101512# for output, the original token is needed FormulaToken* pOrigToken = (_pToken->GetType() == svFAP) ? _pToken->GetFAPOrigToken() : _pToken; uno::Sequence<sheet::FormulaToken> aArgs(1); - aArgs[0] = m_aTokenMap.find(pOrigToken)->second; + ::std::map<FormulaToken*,sheet::FormulaToken>::const_iterator itr = m_aTokenMap.find(pOrigToken); + if (itr == m_aTokenMap.end()) + return; + + aArgs[0] = itr->second; try { const table::CellAddress aRefPos(m_pHelper->getReferencePosition()); diff --git a/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu b/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu index ccd1e979fbef..031a01a831a1 100644 --- a/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu +++ b/officecfg/registry/data/org/openoffice/Office/UI/BasicIDEWindowState.xcu @@ -146,6 +146,20 @@ <value>true</value> </prop> </node> + <node oor:name="private:resource/toolbar/findbar" oor:op="replace"> + <prop oor:name="DockPos" oor:type="xs:string"> + <value>1,0</value> + </prop> + <prop oor:name="DockingArea" oor:type="xs:int"> + <value>1</value> + </prop> + <prop oor:name="UIName" oor:type="xs:string"> + <value xml:lang="en-US">Find</value> + </prop> + <prop oor:name="Visible" oor:type="xs:boolean"> + <value>false</value> + </prop> + </node> </node> </node> </oor:component-data> diff --git a/scripting/util/provider/beanshell/makefile.mk b/scripting/util/provider/beanshell/makefile.mk index cbb0c40e6215..a7c74f51803c 100755 --- a/scripting/util/provider/beanshell/makefile.mk +++ b/scripting/util/provider/beanshell/makefile.mk @@ -36,6 +36,9 @@ EXTENSIONNAME:=ScriptProviderForBeanShell EXTENSION_ZIPNAME:=script-provider-for-beanshell COMPONENT_JARFILES=$(EXTENSIONDIR)$/$(EXTENSIONNAME).jar +.IF "$(SYSTEM_BSH)" != "YES" +EXTENSION_PACKDEPS=$(SOLARBINDIR)$/bsh.jar +.ENDIF .IF "$(ENABLE_SCRIPTING_BEANSHELL)" != "YES" @all: @@ -46,6 +49,16 @@ COMPONENT_JARFILES=$(EXTENSIONDIR)$/$(EXTENSIONNAME).jar .INCLUDE : target.mk .INCLUDE : extension_post.mk +.IF "$(SYSTEM_BSH)" != "YES" + +ALLTAR : $(EXTENSIONDIR)$/bsh.jar + +$(EXTENSIONDIR)$/bsh.jar : $(SOLARBINDIR)$/bsh.jar + @@-$(MKDIRHIER) $(@:d) + $(COMMAND_ECHO)$(COPY) $< $@ + +.ENDIF + .ELSE .INCLUDE : target.mk diff --git a/scripting/util/provider/javascript/manifest.xml b/scripting/util/provider/javascript/manifest.xml index 4c61747f4dcf..d052ad8bc3ea 100755 --- a/scripting/util/provider/javascript/manifest.xml +++ b/scripting/util/provider/javascript/manifest.xml @@ -3,8 +3,5 @@ <manifest:manifest xmlns:manifest="http://openoffice.org/2001/manifest"> <manifest:file-entry manifest:media-type="application/vnd.sun.star.uno-component;type=java" - manifest:full-path="js.jar"/> - <manifest:file-entry - manifest:media-type="application/vnd.sun.star.uno-component;type=java" manifest:full-path="ScriptProviderForJavaScript.jar"/> </manifest:manifest> diff --git a/sfx2/inc/sfx2/objsh.hxx b/sfx2/inc/sfx2/objsh.hxx index 4ba6c57e1a2b..76be70a00f05 100644 --- a/sfx2/inc/sfx2/objsh.hxx +++ b/sfx2/inc/sfx2/objsh.hxx @@ -230,6 +230,9 @@ protected: /// template method, called by FlushDocInfo; this implementation is empty virtual void DoFlushDocInfo(); + // helper method + void AddToRecentlyUsedList(); + public: TYPEINFO(); SFX_DECL_INTERFACE(SFX_INTERFACE_SFXDOCSH) diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx index 09f9abfd1e01..282643a11502 100644 --- a/sfx2/source/appl/sfxhelp.cxx +++ b/sfx2/source/appl/sfxhelp.cxx @@ -188,6 +188,15 @@ void AppendConfigToken( String& rURL, sal_Bool bQuestionMark, const rtl::OUStrin rURL += DEFINE_CONST_UNICODE("&System="); rURL += SvtHelpOptions().GetSystem(); + static rtl::OUString aVersion; + if ( aVersion.isEmpty() ) + aVersion = utl::Bootstrap::getProductVersion(); + + if ( !aVersion.isEmpty() ) + { + rURL += DEFINE_CONST_UNICODE( "&Version=" ); + rURL += String( aVersion ); + } } sal_Bool GetHelpAnchor_Impl( const String& _rURL, String& _rAnchor ) diff --git a/sfx2/source/dialog/passwd.cxx b/sfx2/source/dialog/passwd.cxx index c5e41227896a..41a5de5650f1 100644 --- a/sfx2/source/dialog/passwd.cxx +++ b/sfx2/source/dialog/passwd.cxx @@ -165,6 +165,9 @@ SfxPasswordDialog::SfxPasswordDialog( Window* pParent, const String* pGroupText // add second confirm line xEdits->addRow( &maConfirm2FT, &maConfirm2ED, -2, aEditSize ); + // add password length warning line + xEdits->addWindow( &maMinLengthFT ); + // add a FixedLine FixedLine* pLine = new FixedLine( this, 0 ); pLine->Show(); diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx index 7d825b6fa846..553cb872f82b 100644 --- a/sfx2/source/doc/objstor.cxx +++ b/sfx2/source/doc/objstor.cxx @@ -821,15 +821,7 @@ sal_Bool SfxObjectShell::DoLoad( SfxMedium *pMed ) && !( pPreviewItem && pPreviewItem->GetValue() ) && !( pHiddenItem && pHiddenItem->GetValue() ) ) { - INetURLObject aUrl( pMedium->GetOrigURL() ); - - if ( aUrl.GetProtocol() == INET_PROT_FILE ) - { - const SfxFilter* pOrgFilter = pMedium->GetOrigFilter(); - Application::AddToRecentDocumentList( - aUrl.GetURLNoPass( INetURLObject::NO_DECODE ), - (pOrgFilter) ? pOrgFilter->GetMimeType() : String() ); - } + AddToRecentlyUsedList(); } } @@ -2085,9 +2077,23 @@ sal_Bool SfxObjectShell::DoSaveCompleted( SfxMedium* pNewMed ) pMedium->ClearBackup_Impl(); pMedium->LockOrigFileOnDemand( sal_True, sal_False ); + AddToRecentlyUsedList(); + return bOk; } +void SfxObjectShell::AddToRecentlyUsedList() +{ + INetURLObject aUrl( pMedium->GetOrigURL() ); + + if ( aUrl.GetProtocol() == INET_PROT_FILE ) + { + const SfxFilter* pOrgFilter = pMedium->GetOrigFilter(); + Application::AddToRecentDocumentList( aUrl.GetURLNoPass( INetURLObject::NO_DECODE ), + (pOrgFilter) ? pOrgFilter->GetMimeType() : String() ); + } +} + //------------------------------------------------------------------------- sal_Bool SfxObjectShell::ConvertFrom diff --git a/svx/AllLangResTarget_svx.mk b/svx/AllLangResTarget_svx.mk index 85c9167b88cc..ae19390676b3 100644 --- a/svx/AllLangResTarget_svx.mk +++ b/svx/AllLangResTarget_svx.mk @@ -106,7 +106,7 @@ $(call gb_SrsTarget_get_clean_target,svx/res) : $(WORKDIR)/inc/svx/globlmn.hrc_c # hack !!! # just a temporary - globlmn.hrc about to be removed! ifeq ($(strip $(WITH_LANG)),) -$(WORKDIR)/inc/svx/globlmn.hrc : $(SRCDIR)/svx/inc/globlmn_tmpl.hrc +$(WORKDIR)/inc/svx/globlmn.hrc : $(realpath $(SRCDIR)/svx/inc/globlmn_tmpl.hrc) echo copying $@ -mkdir -p $(WORKDIR)/inc/svx cp $< $@ @@ -117,7 +117,7 @@ else ifneq ($(gb_lastrun_globlmn),MERGED) .PHONY : $(WORKDIR)/inc/svx/globlmn.hrc endif -$(WORKDIR)/inc/svx/globlmn.hrc : $(SRCDIR)/svx/inc/globlmn_tmpl.hrc $(gb_SrsPartMergeTarget_SDFLOCATION)/svx/inc/localize.sdf +$(WORKDIR)/inc/svx/globlmn.hrc : $(realpath $(SRCDIR)/svx/inc/globlmn_tmpl.hrc) $(realpath $(gb_SrsPartMergeTarget_SDFLOCATION)/svx/inc/localize.sdf) echo merging $@ -mkdir -p $(WORKDIR)/inc/svx rm -f $(WORKDIR)/inc/svx/lastrun.mk @@ -125,7 +125,7 @@ $(WORKDIR)/inc/svx/globlmn.hrc : $(SRCDIR)/svx/inc/globlmn_tmpl.hrc $(gb_SrsPart $(call gb_Helper_abbreviate_dirs_native, \ $(gb_SrsPartMergeTarget_TRANSEXCOMMAND) \ -p svx \ - -i $< -o $@ -m $(gb_SrsPartMergeTarget_SDFLOCATION)/svx/inc/localize.sdf -l all) + -i $< -o $@ -m $(realpath $(gb_SrsPartMergeTarget_SDFLOCATION)/svx/inc/localize.sdf) -l all) $(call gb_Deliver_deliver, $@, $(OUTDIR)/inc/svx/globlmn.hrc) endif diff --git a/svx/source/svdraw/svdattr.cxx b/svx/source/svdraw/svdattr.cxx index 1e38fb7167ca..d480cc45bab5 100644 --- a/svx/source/svdraw/svdattr.cxx +++ b/svx/source/svdraw/svdattr.cxx @@ -150,7 +150,7 @@ SdrItemPool::SdrItemPool( mppLocalPoolDefaults[SDRATTR_CUSTOMSHAPE_ADJUSTMENT -SDRATTR_START]=new SdrCustomShapeAdjustmentItem; mppLocalPoolDefaults[SDRATTR_XMLATTRIBUTES -SDRATTR_START]=new SvXMLAttrContainerItem( SDRATTR_XMLATTRIBUTES ); mppLocalPoolDefaults[SDRATTR_TEXT_USEFIXEDCELLHEIGHT -SDRATTR_START]=new SdrTextFixedCellHeightItem; - mppLocalPoolDefaults[SDRATTR_TEXT_WORDWRAP -SDRATTR_START]=new SdrTextWordWrapItem; + mppLocalPoolDefaults[SDRATTR_TEXT_WORDWRAP -SDRATTR_START]=new SdrTextWordWrapItem( sal_True ); mppLocalPoolDefaults[SDRATTR_TEXT_AUTOGROWSIZE -SDRATTR_START]=new SdrTextAutoGrowSizeItem; mppLocalPoolDefaults[SDRATTR_EDGEKIND -SDRATTR_START]=new SdrEdgeKindItem; mppLocalPoolDefaults[SDRATTR_EDGENODE1HORZDIST-SDRATTR_START]=new SdrEdgeNode1HorzDistItem(nDefEdgeDist); diff --git a/svx/source/svdraw/svdedxv.cxx b/svx/source/svdraw/svdedxv.cxx index d0cb45fe3d61..18876c50a14d 100644 --- a/svx/source/svdraw/svdedxv.cxx +++ b/svx/source/svdraw/svdedxv.cxx @@ -454,8 +454,9 @@ OutlinerView* SdrObjEditView::ImpMakeOutlinerView(Window* pWin, sal_Bool /*bNoPa pOutlView->SetAnchorMode((EVAnchorMode)(pText->GetOutlinerViewAnchorMode())); pTextEditOutliner->SetFixedCellHeight(((const SdrTextFixedCellHeightItem&)pText->GetMergedItem(SDRATTR_TEXT_USEFIXEDCELLHEIGHT)).GetValue()); } - pOutlView->SetOutputArea(aTextEditArea); + // do update before setting output area so that aTextEditArea can be recalculated pTextEditOutliner->SetUpdateMode(sal_True); + pOutlView->SetOutputArea(aTextEditArea); ImpInvalidateOutlinerView(*pOutlView); return pOutlView; } diff --git a/svx/source/svdraw/svdoashp.cxx b/svx/source/svdraw/svdoashp.cxx index 28a0344a8302..f615a0e5e704 100644 --- a/svx/source/svdraw/svdoashp.cxx +++ b/svx/source/svdraw/svdoashp.cxx @@ -1386,6 +1386,16 @@ void SdrObjCustomShape::TakeObjInfo(SdrObjTransformInfoRec& rInfo) const { rInfo.bCanConvToContour = aInfo.bCanConvToContour; } + + if(rInfo.bShearAllowed != aInfo.bShearAllowed) + { + rInfo.bShearAllowed = aInfo.bShearAllowed; + } + + if(rInfo.bEdgeRadiusAllowed != aInfo.bEdgeRadiusAllowed) + { + rInfo.bEdgeRadiusAllowed = aInfo.bEdgeRadiusAllowed; + } } } } diff --git a/sysui/desktop/freedesktop/freedesktop-menus.spec b/sysui/desktop/freedesktop/freedesktop-menus.spec index 8cec36901e9f..1cb1554a6a5f 100755 --- a/sysui/desktop/freedesktop/freedesktop-menus.spec +++ b/sysui/desktop/freedesktop/freedesktop-menus.spec @@ -40,7 +40,6 @@ umask 0000 export DESTDIR=$RPM_BUILD_ROOT export KDEMAINDIR=/usr export GNOMEDIR=/usr -export GNOME_MIME_THEME=hicolor ./create_tree.sh @@ -105,6 +104,54 @@ if [ "$1" = "1" ] ; then # first install fi fi +# add symlinks so that nautilus can identify the mime-icons +# not strictly freedesktop-stuff but there is no common naming scheme yet. +# One proposal is "mime-application:vnd.oasis.opendocument.spreadsheet.png" +# for e.g. application/vnd.oasis.opendocument.spreadsheet +link_target_root="/opt/gnome/share/icons/hicolor" + +if [ ! -d "${link_target_root}" ] +then + link_target_root="/opt/gnome/share/icons/gnome" +fi + +for subdir in `cd ${link_target_root}; ls -d *` +do + link_dir="/opt/gnome/share/icons/hicolor/$subdir/mimetypes" + link_target_dir="../../../gnome/$subdir/mimetypes" + + test -d ${link_dir}/${link_target_dir} || continue; + + if [ ! -d "${link_dir}" ] + then + mkdir -p "${link_dir}" + fi + + icon=%iconprefix-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.png + icon=%iconprefix-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.template.png + icon=%iconprefix-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.math.png + icon=%iconprefix-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.global.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.base.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.database.png + icon=%iconprefix-oasis-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics.png + icon=%iconprefix-oasis-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics-template.png + icon=%iconprefix-oasis-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.formula.png + icon=%iconprefix-oasis-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-master.png + icon=%iconprefix-oasis-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation.png + icon=%iconprefix-oasis-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation-template.png + icon=%iconprefix-oasis-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet.png + icon=%iconprefix-oasis-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet-template.png + icon=%iconprefix-oasis-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text.png + icon=%iconprefix-oasis-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-template.png + icon=%iconprefix-oasis-web-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-web.png + icon=%iconprefix-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.png + icon=%iconprefix-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.template.png + icon=%iconprefix-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.png + icon=%iconprefix-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.template.png + icon=%iconprefix-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.png + icon=%iconprefix-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.template.png + icon=%iconprefix-extension.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.openofficeorg.extension.png +done #run always for theme in gnome hicolor locolor; do @@ -326,9 +373,9 @@ done # glibc breaks rpm unless rpm is build with internal glob-matching (issue 49374) # https://bugzilla.redhat.com/beta/show_bug.cgi?id=134362 %defattr(-, root, root) -%if %unixfilename != libreoffice +%if "%unixfilename" != "libreoffice%productversion" # compat symlinks -%attr(0755, root, root) /opt/%unixfilename +%attr(0755,root,root) /opt/%unixfilename %endif %attr(0755, root, root) /usr/bin/* /usr/share/applications/%unixfilename-base.desktop diff --git a/sysui/desktop/mandriva/mandriva-menus.spec b/sysui/desktop/mandriva/mandriva-menus.spec index a2c52de584ff..47f64ed226cb 100755 --- a/sysui/desktop/mandriva/mandriva-menus.spec +++ b/sysui/desktop/mandriva/mandriva-menus.spec @@ -317,11 +317,11 @@ fi %files -%if %unixfilename != libreoffice +%if "%unixfilename" != "libreoffice%productversion" # compat symlinks %attr(0755,root,root) /opt/%unixfilename -%attr(0755,root,root) /usr/bin/libreoffice -%attr(0755,root,root) /usr/bin/libreoffice-printeradmin +%attr(0755,root,root) /usr/bin/libreoffice%productversion +%attr(0755,root,root) /usr/bin/libreoffice%productversion-printeradmin %endif %attr(0755,root,root) %verify(not size md5) /usr/bin/%unixfilename %attr(0755,root,root) /usr/bin/%unixfilename-printeradmin diff --git a/sysui/desktop/productversion.mk b/sysui/desktop/productversion.mk index 12512cef8418..9c0eafb7922e 100755 --- a/sysui/desktop/productversion.mk +++ b/sysui/desktop/productversion.mk @@ -62,7 +62,7 @@ PRODUCTNAME.libreoffice = LibreOffice PRODUCTVERSION.libreoffice = $(PRODUCTVERSION) PRODUCTVERSIONSHORT.libreoffice = $(PRODUCTVERSIONSHORT) PKGVERSION.libreoffice = $(PKGVERSION) -UNIXFILENAME.libreoffice = $(PRODUCTNAME.libreoffice:l) +UNIXFILENAME.libreoffice = $(PRODUCTNAME.libreoffice:l)$(PRODUCTVERSION.libreoffice) ICONPREFIX.libreoffice = $(UNIXFILENAME.libreoffice:s/.//g) PRODUCTNAME.oxygenoffice = OxygenOffice diff --git a/sysui/desktop/redhat/redhat-menus.spec b/sysui/desktop/redhat/redhat-menus.spec index cab8cc559896..e58f205831d3 100755 --- a/sysui/desktop/redhat/redhat-menus.spec +++ b/sysui/desktop/redhat/redhat-menus.spec @@ -28,7 +28,6 @@ mkdir -p $RPM_BUILD_ROOT export DESTDIR=$RPM_BUILD_ROOT export KDEMAINDIR=/usr export GNOMEDIR=/usr -export GNOME_MIME_THEME=hicolor ./create_tree.sh @@ -65,6 +64,55 @@ if [ -x /usr/bin/update-mime-database ]; then update-mime-database /usr/share/mime fi +# add symlinks so that nautilus can identify the mime-icons +# not strictly freedesktop-stuff but there is no common naming scheme yet. +# One proposal is "mime-application:vnd.oasis.opendocument.spreadsheet.png" +# for e.g. application/vnd.oasis.opendocument.spreadsheet +link_target_root="/opt/gnome/share/icons/hicolor" + +if [ ! -d "${link_target_root}" ] +then + link_target_root="/opt/gnome/share/icons/gnome" +fi + +for subdir in `cd ${link_target_root}; ls -d *` +do + link_dir="/opt/gnome/share/icons/hicolor/$subdir/mimetypes" + link_target_dir="../../../gnome/$subdir/mimetypes" + + test -d ${link_dir}/${link_target_dir} || continue; + + if [ ! -d "${link_dir}" ] + then + mkdir -p "${link_dir}" + fi + + icon=%iconprefix-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.png + icon=%iconprefix-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.template.png + icon=%iconprefix-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.math.png + icon=%iconprefix-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.global.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.base.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.database.png + icon=%iconprefix-oasis-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics.png + icon=%iconprefix-oasis-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics-template.png + icon=%iconprefix-oasis-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.formula.png + icon=%iconprefix-oasis-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-master.png + icon=%iconprefix-oasis-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation.png + icon=%iconprefix-oasis-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation-template.png + icon=%iconprefix-oasis-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet.png + icon=%iconprefix-oasis-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet-template.png + icon=%iconprefix-oasis-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text.png + icon=%iconprefix-oasis-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-template.png + icon=%iconprefix-oasis-web-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-web.png + icon=%iconprefix-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.png + icon=%iconprefix-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.template.png + icon=%iconprefix-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.png + icon=%iconprefix-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.template.png + icon=%iconprefix-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.png + icon=%iconprefix-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.template.png + icon=%iconprefix-extension.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.openofficeorg.extension.png +done + # run only on first install, since postun is run when updating # post would be run before the old files are removed if [ "$1" = "1" ] ; then # first install @@ -275,13 +323,14 @@ for theme in gnome hicolor locolor; do true fi done +echo unixfilename=%unixfilename %files -%if %unixfilename != libreoffice +%if "%unixfilename" != "libreoffice%productversion" # compat symlinks %attr(0755,root,root) /opt/%unixfilename -%attr(0755,root,root) /usr/bin/libreoffice -%attr(0755,root,root) /usr/bin/libreoffice-printeradmin +%attr(0755,root,root) /usr/bin/libreoffice%productversion +%attr(0755,root,root) /usr/bin/libreoffice%productversion-printeradmin %endif %attr(0755,root,root) %verify(not size md5) /usr/bin/%unixfilename %attr(0755,root,root) /usr/bin/%unixfilename-printeradmin diff --git a/sysui/desktop/share/create_tree.sh b/sysui/desktop/share/create_tree.sh index 2fe78c36a4ec..d0c4e7621d9d 100755 --- a/sysui/desktop/share/create_tree.sh +++ b/sysui/desktop/share/create_tree.sh @@ -39,55 +39,6 @@ then mkdir -p ${DESTDIR}/${GNOMEDIR}/share/application-registry cp openoffice.applications ${DESTDIR}/${GNOMEDIR}/share/application-registry/${PREFIX}.applications chmod 0644 ${DESTDIR}/${GNOMEDIR}/share/application-registry/${PREFIX}.* - - if [ "${GNOME_MIME_THEME}" ] - then - echo "Creating legacy mimetype symlinks for GNOME .." - # add symlinks so that nautilus can identify the mime-icons - # not strictly freedesktop-stuff but there is no common naming scheme yet. - # One proposal is "mime-application:vnd.oasis.opendocument.spreadsheet.png" - # for e.g. application/vnd.oasis.opendocument.spreadsheet - link_target_root="${DESTDIR}/${GNOMEDIR}/share/icons/${GNOME_MIME_THEME}" - if [ ! -d "${link_target_root}" ] - then - link_target_root="${DESTDIR}/${GNOMEDIR}/share/icons/gnome" - fi - - for subdir in `cd ${link_target_root}; ls -d *` - do - link_target_dir="" - link_dir="${DESTDIR}/${GNOMEDIR}/share/icons/${GNOME_MIME_THEME}/$subdir/mimetypes" - if [ ! -d "${link_dir}" ] - then - mkdir -p "${link_dir}" - link_target_dir="../../../gnome/$subdir/mimetypes/" - fi - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}drawing.png ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}drawing-template.png ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}formula.png ${link_dir}/gnome-mime-application-vnd.sun.xml.math.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}master-document.png ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.global.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-database.png ${link_dir}/gnome-mime-application-vnd.sun.xml.base.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-database.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.database.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-drawing.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-drawing-template.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics-template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-formula.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.formula.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-master-document.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-master.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-presentation.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-presentation-template.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation-template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-spreadsheet.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-spreadsheet-template.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet-template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-text.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-text-template.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}oasis-web-template.png ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-web.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}presentation.png ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}presentation-template.png ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}spreadsheet.png ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}spreadsheet-template.png ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}text.png ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}text-template.png ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.template.png - ln -sf $link_target_dir${ICON_PREFIX:-}${ICON_PREFIX:+-}extension.png ${link_dir}/gnome-mime-application-vnd.openofficeorg.extension.png - done - fi fi mkdir -p ${DESTDIR}/usr/bin @@ -101,17 +52,17 @@ ln -sf ${office_root}/program/soffice ${DESTDIR}/usr/bin/${PREFIX} cp printeradmin.sh ${DESTDIR}/usr/bin/${PREFIX}-printeradmin chmod 0755 ${DESTDIR}/usr/bin/${PREFIX} ${DESTDIR}/usr/bin/${PREFIX}-printeradmin -if test "${PREFIX}" != libreoffice ; then +if test "${PREFIX}" != libreoffice${PRODUCTVERSION} ; then # compat symlinks mkdir -p ${DESTDIR}${office_prefix} - ln -sf libreoffice ${DESTDIR}${office_root} - ln -sf /usr/bin/${PREFIX} ${DESTDIR}/usr/bin/libreoffice - ln -sf /usr/bin/${PREFIX}-printeradmin ${DESTDIR}/usr/bin/libreoffice-printeradmin + ln -sf libreoffice${PRODUCTVERSION} ${DESTDIR}${office_root} + ln -sf /usr/bin/${PREFIX} ${DESTDIR}/usr/bin/libreoffice${PRODUCTVERSION} + ln -sf /usr/bin/${PREFIX}-printeradmin ${DESTDIR}/usr/bin/libreoffice${PRODUCTVERSION}-printeradmin fi mkdir -p ${DESTDIR}/usr/share/mime/packages -cp openoffice.org.xml ${DESTDIR}/usr/share/mime/packages/libreoffice.xml -chmod 0644 ${DESTDIR}/usr/share/mime/packages/libreoffice.xml +cp openoffice.org.xml ${DESTDIR}/usr/share/mime/packages/libreoffice${PRODUCTVERSION}.xml +chmod 0644 ${DESTDIR}/usr/share/mime/packages/libreoffice${PRODUCTVERSION}.xml mkdir -p ${DESTDIR}/usr/share/applications for i in `cat launcherlist`; do diff --git a/sysui/desktop/share/makefile.mk b/sysui/desktop/share/makefile.mk index 72ba78b99721..9104d1bee955 100755 --- a/sysui/desktop/share/makefile.mk +++ b/sysui/desktop/share/makefile.mk @@ -150,7 +150,7 @@ $(LAUNCHERFLAGFILE) : $(LAUNCHERDEPN) @@-$(MKDIRHIER) $(@:db).$(INPATH).$(@:f) @echo Creating desktop entries for $(@:f) .. @echo --------------------------------- - @$(PERL) brand.pl -p '$${{PRODUCTNAME}} $${{PRODUCTVERSION}}' -u $(UNIXWRAPPERNAME) --iconprefix '$${{WITHOUTDOTUNIXPRODUCTNAME}}-' $< $(@:db).$(INPATH).$(@:f) + @$(PERL) brand.pl -p '$${{PRODUCTNAME}} $${{PRODUCTVERSION}}' -u $(UNIXWRAPPERNAME) --iconprefix '$(ICONPREFIX.libreoffice)-' $< $(@:db).$(INPATH).$(@:f) @$(PERL) translate.pl -p '$${{PRODUCTNAME}} $${{PRODUCTVERSION}}' -d $(@:db).$(INPATH).$(@:f) --ext "desktop" --key "Name" $(ULFDIR)$/launcher_name.ulf @$(PERL) translate.pl -p '$${{PRODUCTNAME}} $${{PRODUCTVERSION}}' -d $(@:db).$(INPATH).$(@:f) --ext "desktop" --key "Comment" $(ULFDIR)$/launcher_comment.ulf @$(PERL) translate.pl -p '$${{PRODUCTNAME}} $${{PRODUCTVERSION}}' -d $(@:db).$(INPATH).$(@:f) --ext "desktop" --key "GenericName" $(ULFDIR)$/launcher_genericname.ulf @@ -224,6 +224,7 @@ $(COMMONMISC)$/{$(PRODUCTLIST)}$/create_tree.sh : $$(@:f) @echo "PREFIX=$(UNIXFILENAME.$(@:d:d:f))" >> $@.$(INPATH) @echo "ICON_PREFIX=$(ICONPREFIX.$(@:d:d:f))" >> $@.$(INPATH) @echo "ICON_SOURCE_DIR=../../../desktop/icons" >> $@.$(INPATH) + @echo "PRODUCTVERSION=$(PRODUCTVERSION.$(@:d:d:f))" >> $@.$(INPATH) @cat $< >> $@.$(INPATH) @chmod 774 $@.$(INPATH) @mv -f $@.$(INPATH) $@ diff --git a/sysui/desktop/suse/suse-menus.spec b/sysui/desktop/suse/suse-menus.spec index 6f4ef8ade3ee..5914203b9dd2 100755 --- a/sysui/desktop/suse/suse-menus.spec +++ b/sysui/desktop/suse/suse-menus.spec @@ -33,7 +33,6 @@ mkdir -p $RPM_BUILD_ROOT export DESTDIR=$RPM_BUILD_ROOT export KDEMAINDIR=/opt/kde3 export GNOMEDIR=/opt/gnome -export GNOME_MIME_THEME=hicolor ./create_tree.sh @@ -74,6 +73,55 @@ if [ -x /opt/gnome/bin/update-desktop-database ]; then /opt/gnome/bin/update-desktop-database fi +# add symlinks so that nautilus can identify the mime-icons +# not strictly freedesktop-stuff but there is no common naming scheme yet. +# One proposal is "mime-application:vnd.oasis.opendocument.spreadsheet.png" +# for e.g. application/vnd.oasis.opendocument.spreadsheet +link_target_root="/opt/gnome/share/icons/hicolor" + +if [ ! -d "${link_target_root}" ] +then + link_target_root="/opt/gnome/share/icons/gnome" +fi + +for subdir in `cd ${link_target_root}; ls -d *` +do + link_dir="/opt/gnome/share/icons/hicolor/$subdir/mimetypes" + link_target_dir="../../../gnome/$subdir/mimetypes" + + test -d ${link_dir}/${link_target_dir} || continue; + + if [ ! -d "${link_dir}" ] + then + mkdir -p "${link_dir}" + fi + + icon=%iconprefix-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.png + icon=%iconprefix-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.draw.template.png + icon=%iconprefix-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.math.png + icon=%iconprefix-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.global.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.base.png + icon=%iconprefix-oasis-database.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.database.png + icon=%iconprefix-oasis-drawing.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics.png + icon=%iconprefix-oasis-drawing-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.graphics-template.png + icon=%iconprefix-oasis-formula.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.formula.png + icon=%iconprefix-oasis-master-document.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-master.png + icon=%iconprefix-oasis-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation.png + icon=%iconprefix-oasis-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.presentation-template.png + icon=%iconprefix-oasis-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet.png + icon=%iconprefix-oasis-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.spreadsheet-template.png + icon=%iconprefix-oasis-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text.png + icon=%iconprefix-oasis-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-template.png + icon=%iconprefix-oasis-web-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.oasis.opendocument.text-web.png + icon=%iconprefix-presentation.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.png + icon=%iconprefix-presentation-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.impress.template.png + icon=%iconprefix-spreadsheet.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.png + icon=%iconprefix-spreadsheet-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.calc.template.png + icon=%iconprefix-text.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.png + icon=%iconprefix-text-template.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.sun.xml.writer.template.png + icon=%iconprefix-extension.png; test -f ${link_dir}/${link_target_dir}/$icon && ln -sf ${link_target_dir}/${icon} ${link_dir}/gnome-mime-application-vnd.openofficeorg.extension.png +done + # run only on first install, since postun is run when updating # post would be run before the old files are removed if [ "$1" = "1" ] ; then # first install @@ -289,11 +337,11 @@ for themedir in /opt/gnome/share/icons/gnome /opt/gnome/share/icons/hicolor /opt done %files -%if %unixfilename != libreoffice +%if "%unixfilename" != "libreoffice%productversion" # compat symlinks %attr(0755,root,root) /opt/%unixfilename -%attr(0755,root,root) /usr/bin/libreoffice -%attr(0755,root,root) /usr/bin/libreoffice-printeradmin +%attr(0755,root,root) /usr/bin/libreoffice%productversion +%attr(0755,root,root) /usr/bin/libreoffice%productversion-printeradmin %endif %attr(0755,root,root) %verify(not size md5) /usr/bin/%unixfilename %attr(0755,root,root) /usr/bin/%unixfilename-printeradmin @@ -313,7 +361,6 @@ done /opt/kde3/share/mimelnk/application/*.desktop /opt/gnome/share/icons/gnome/*/apps/*png /opt/gnome/share/icons/gnome/*/mimetypes/*png -/opt/gnome/share/icons/hicolor/*/mimetypes/*png /opt/kde3/share/icons/hicolor/*/apps/*png /opt/kde3/share/icons/hicolor/*/mimetypes/*png /opt/kde3/share/icons/locolor/*/apps/*png diff --git a/sysui/desktop/tg_rpm.mk b/sysui/desktop/tg_rpm.mk index 6fab6e748a99..0ff9af4dca3d 100755 --- a/sysui/desktop/tg_rpm.mk +++ b/sysui/desktop/tg_rpm.mk @@ -38,6 +38,7 @@ $(RPMFLAGFILES) : $(SPECFILE) --define "productname $(PRODUCTNAME.$(@:b:s/-/ /:1))" \ --define "pkgprefix $(@:b:s/-/ /:1)$(PRODUCTVERSION.$(@:b:s/-/ /:1))" \ --define "unixfilename $(UNIXFILENAME.$(@:b:s/-/ /:1))" \ + --define "productversion $(PRODUCTVERSION.$(@:b:s/-/ /:1))" \ --define "iconprefix $(ICONPREFIX.$(@:b:s/-/ /:1))" \ --define "version $(PKGVERSION.$(@:b:s/-/ /:1))" \ --define "release $(PKGREV)" \ diff --git a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx index 7f89f12c4c99..f0ca219e1155 100644 --- a/xmlhelp/source/cxxhelp/provider/urlparameter.cxx +++ b/xmlhelp/source/cxxhelp/provider/urlparameter.cxx @@ -697,6 +697,8 @@ bool URLParameter::query() m_nHitCount = value.toInt32(); else if( parameter.compareToAscii( "Active" ) == 0 ) m_aActive = value; + else if( parameter.compareToAscii( "Version" ) == 0 ) + ; // ignored (but accepted) in the build-in help, useful only for the online help else ret = false; } diff --git a/xmloff/inc/xmloff/xmltoken.hxx b/xmloff/inc/xmloff/xmltoken.hxx index e9f00e519a34..a923f467ea2d 100644 --- a/xmloff/inc/xmloff/xmltoken.hxx +++ b/xmloff/inc/xmloff/xmltoken.hxx @@ -2105,6 +2105,7 @@ namespace xmloff { namespace token { XML_LAYOUT_GRID_STANDARD_MODE, XML_LAYOUT_GRID_BASE_WIDTH, XML_LAYOUT_GRID_SNAP_TO_CHARS, + XML_LAYOUT_GRID_SNAP_TO, XML_SNAP_TO_LAYOUT_GRID, XML_DONT_BALANCE_TEXT_COLUMNS, diff --git a/xmloff/source/core/xmltoken.cxx b/xmloff/source/core/xmltoken.cxx index e473551e5f68..b07e77a9bedf 100644 --- a/xmloff/source/core/xmltoken.cxx +++ b/xmloff/source/core/xmltoken.cxx @@ -2113,7 +2113,8 @@ namespace xmloff { namespace token { TOKEN( "default-page-layout", XML_DEFAULT_PAGE_LAYOUT ), TOKEN( "layout-grid-standard-mode", XML_LAYOUT_GRID_STANDARD_MODE ), TOKEN( "layout-grid-base-width", XML_LAYOUT_GRID_BASE_WIDTH ), - TOKEN( "layout-grid-snap-to-characters", XML_LAYOUT_GRID_SNAP_TO_CHARS ), + TOKEN( "layout-grid-snap-to-characters", XML_LAYOUT_GRID_SNAP_TO_CHARS ), + TOKEN( "layout-grid-snap-to", XML_LAYOUT_GRID_SNAP_TO ), TOKEN( "snap-to-layout-grid", XML_SNAP_TO_LAYOUT_GRID ), diff --git a/xmloff/source/style/PageMasterStyleMap.cxx b/xmloff/source/style/PageMasterStyleMap.cxx index 52f02ef4afd9..f207f7d7f43a 100644 --- a/xmloff/source/style/PageMasterStyleMap.cxx +++ b/xmloff/source/style/PageMasterStyleMap.cxx @@ -111,6 +111,7 @@ const XMLPropertyMapEntry aXMLPageMasterStyleMap[] = //text grid enhancement for better CJK support PLMAP( "GridBaseWidth", XML_NAMESPACE_STYLE, XML_LAYOUT_GRID_BASE_WIDTH, XML_TYPE_MEASURE, CTP_PM_GRID_BASE_WIDTH ), + PLMAP( "GridSnapToChars", XML_NAMESPACE_STYLE, XML_LAYOUT_GRID_SNAP_TO, XML_TYPE_BOOL, CTP_PM_GRID_SNAP_TO_CHARS ), PLMAP( "GridSnapToChars", XML_NAMESPACE_STYLE, XML_LAYOUT_GRID_SNAP_TO_CHARS, XML_TYPE_BOOL, CTP_PM_GRID_SNAP_TO_CHARS ), //export as a default attribute PLMAP( "StandardPageMode", XML_NAMESPACE_STYLE, XML_LAYOUT_GRID_STANDARD_MODE, XML_TYPE_BOOL|MID_FLAG_DEFAULT_ITEM_EXPORT, CTF_PM_STANDARD_MODE ), diff --git a/xmloff/source/text/txtimp.cxx b/xmloff/source/text/txtimp.cxx index ab73ee1f86f1..e81610773293 100644 --- a/xmloff/source/text/txtimp.cxx +++ b/xmloff/source/text/txtimp.cxx @@ -2678,7 +2678,8 @@ void XMLTextImportHelper::pushFieldCtx( ::rtl::OUString name, ::rtl::OUString ty void XMLTextImportHelper::popFieldCtx() { - m_pImpl->m_FieldStack.pop(); + if ( !m_pImpl->m_FieldStack.empty() ) + m_pImpl->m_FieldStack.pop(); } void XMLTextImportHelper::addFieldParam( ::rtl::OUString name, ::rtl::OUString value ) |