[Libreoffice-commits] .: 2 commits - fpicker/source framework/source sfx2/source svx/source
Caolán McNamara
caolan at kemper.freedesktop.org
Thu Jan 27 04:15:10 PST 2011
fpicker/source/office/iodlg.cxx | 1 -
framework/source/classes/fwktabwindow.cxx | 3 +--
framework/source/helper/actiontriggerhelper.cxx | 2 --
framework/source/layoutmanager/layoutmanager.cxx | 6 +-----
sfx2/source/appl/shutdowniconunx.cxx | 18 +++++++++++++++---
svx/source/dialog/measctrl.cxx | 1 -
svx/source/form/fmsrcimp.cxx | 2 +-
svx/source/gallery2/gallery1.cxx | 12 ++----------
svx/source/stbctrls/modctrl.cxx | 1 -
svx/source/stbctrls/xmlsecctrl.cxx | 2 --
svx/source/svdraw/svdcrtv.cxx | 5 -----
svx/source/tbxctrls/layctrl.cxx | 2 --
12 files changed, 20 insertions(+), 35 deletions(-)
New commits:
commit f167cafd5edfcac674a556fa2f813ce0dec34303
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Jan 27 12:14:17 2011 +0000
Related: rhbz#610103 more woes on rpm upgrade vs rpm erase
diff --git a/sfx2/source/appl/shutdowniconunx.cxx b/sfx2/source/appl/shutdowniconunx.cxx
index 5618e73..cfbf974 100644
--- a/sfx2/source/appl/shutdowniconunx.cxx
+++ b/sfx2/source/appl/shutdowniconunx.cxx
@@ -333,13 +333,25 @@ static gboolean display_menu_cb( GtkWidget *,
* upgraded, then the old quickstarter is still running, but is now unreliable
* as the old install has been deleted. A fairly intractable problem but we
* can avoid much of the pain if we turn off the quickstarter if we detect
- * that it has been physically deleted.
+ * that it has been physically deleted or overwritten
*/
static void notify_file_changed(GFileMonitor * /*gfilemonitor*/, GFile * /*arg1*/,
GFile * /*arg2*/, GFileMonitorEvent event_type, gpointer /*user_data*/)
{
- if (event_type == G_FILE_MONITOR_EVENT_DELETED)
- exit_quickstarter_cb(NULL);
+ //Shutdown the quick starter if anything has happened to make it unsafe
+ //to remain running, e.g. rpm --erased and all libs deleted, or
+ //rpm --upgrade and libs being overwritten
+ switch (event_type)
+ {
+ case G_FILE_MONITOR_EVENT_DELETED:
+ case G_FILE_MONITOR_EVENT_CREATED:
+ case G_FILE_MONITOR_EVENT_PRE_UNMOUNT:
+ case G_FILE_MONITOR_EVENT_UNMOUNTED:
+ exit_quickstarter_cb(GTK_WIDGET(pTrayIcon));
+ break;
+ default:
+ break;
+ }
}
#endif
commit b560aee0ed84a65d0422f55faee26de40ee3aeeb
Author: Caolán McNamara <caolanm at redhat.com>
Date: Thu Jan 27 11:24:02 2011 +0000
WaE: gcc 4.6.0 various warnings
diff --git a/fpicker/source/office/iodlg.cxx b/fpicker/source/office/iodlg.cxx
index ca0ffb8..4c1f1ad 100644
--- a/fpicker/source/office/iodlg.cxx
+++ b/fpicker/source/office/iodlg.cxx
@@ -2489,7 +2489,6 @@ void SvtFileDialog::InitSize()
if ( !_pImp->_nFixDeltaHeight )
{
// Fixgr"ossen errechnen und merken
- Point aPnt = _pFileView->GetPosPixel();
long nBoxH = _pFileView->GetSizePixel().Height();
long nH = GetSizePixel().Height();
_pImp->_nFixDeltaHeight = nH - nBoxH;
diff --git a/framework/source/classes/fwktabwindow.cxx b/framework/source/classes/fwktabwindow.cxx
index f163f91..a2d2641 100644
--- a/framework/source/classes/fwktabwindow.cxx
+++ b/framework/source/classes/fwktabwindow.cxx
@@ -194,8 +194,7 @@ void FwkTabPage::Resize()
{
if ( m_xPage.is () )
{
- Size aSize = GetSizePixel ();
- Point aPos = GetPosPixel ();
+ Size aSize = GetSizePixel();
m_xPage->setPosSize( 0, 0, aSize.Width()-1 , aSize.Height()-1, awt::PosSize::POSSIZE );
}
diff --git a/framework/source/helper/actiontriggerhelper.cxx b/framework/source/helper/actiontriggerhelper.cxx
index 1245909..8bbaa2c 100644
--- a/framework/source/helper/actiontriggerhelper.cxx
+++ b/framework/source/helper/actiontriggerhelper.cxx
@@ -138,7 +138,6 @@ void InsertSubMenuItems( Menu* pSubMenu, USHORT& nItemId, Reference< XIndexConta
OUString aHelpURL;
Reference< XBitmap > xBitmap;
Reference< XIndexContainer > xSubContainer;
- sal_Bool bSpecialItemId = sal_False;
USHORT nNewItemId = nItemId++;
GetMenuItemAttributes( xPropSet, aLabel, aCommandURL, aHelpURL, xBitmap, xSubContainer );
@@ -153,7 +152,6 @@ void InsertSubMenuItems( Menu* pSubMenu, USHORT& nItemId, Reference< XIndexConta
// command url but uses the item id as a unqiue identifier. These entries
// got a special url during conversion from menu=>actiontriggercontainer.
// Now we have to extract this special url and set the correct item id!!!
- bSpecialItemId = sal_True;
nNewItemId = (USHORT)aCommandURL.copy( nIndex+aSlotURL.getLength() ).toInt32();
pSubMenu->InsertItem( nNewItemId, aLabel );
}
diff --git a/framework/source/layoutmanager/layoutmanager.cxx b/framework/source/layoutmanager/layoutmanager.cxx
index e5bc34b..bde2e9d 100644
--- a/framework/source/layoutmanager/layoutmanager.cxx
+++ b/framework/source/layoutmanager/layoutmanager.cxx
@@ -4726,7 +4726,6 @@ throw (RuntimeException)
RTL_LOGFILE_CONTEXT( aLog, "framework (cd100003) ::LayoutManager::hideElement" );
- sal_Bool bResult( sal_False );
sal_Bool bNotify( sal_False );
::rtl::OUString aElementType;
::rtl::OUString aElementName;
@@ -4755,7 +4754,6 @@ throw (RuntimeException)
if ( pMenuBar )
{
pMenuBar->SetDisplayable( sal_False );
- bResult = sal_True;
bNotify = sal_True;
}
}
@@ -4774,14 +4772,13 @@ throw (RuntimeException)
implts_writeWindowStateData( m_aStatusBarAlias, m_aStatusBarElement );
doLayout();
bNotify = sal_True;
- bResult = sal_True;
}
}
}
else if ( aElementType.equalsIgnoreAsciiCaseAscii( "progressbar" ) &&
aElementName.equalsIgnoreAsciiCaseAscii( "progressbar" ))
{
- bResult = bNotify = implts_hideProgressBar();
+ bNotify = implts_hideProgressBar();
}
else if ( aElementType.equalsIgnoreAsciiCaseAscii( "toolbar" ))
{
@@ -4806,7 +4803,6 @@ throw (RuntimeException)
if ( xDockWindow.is() && !xDockWindow->isFloating() )
doLayout();
- bResult = sal_True;
bNotify = sal_True;
} // if ( xDockWindow.is() )
break;
diff --git a/svx/source/dialog/measctrl.cxx b/svx/source/dialog/measctrl.cxx
index 1ff587a..2c6afa5 100644
--- a/svx/source/dialog/measctrl.cxx
+++ b/svx/source/dialog/measctrl.cxx
@@ -66,7 +66,6 @@ SvxXMeasurePreview::SvxXMeasurePreview
SetMapMode( aMapMode );
aSize = GetOutputSize();
- Rectangle aRect = Rectangle( Point(), aSize );
Point aPt1 = Point( aSize.Width() / 5, (long) ( aSize.Height() / 2 ) );
Point aPt2 = Point( aSize.Width() * 4 / 5, (long) ( aSize.Height() / 2 ) );
diff --git a/svx/source/form/fmsrcimp.cxx b/svx/source/form/fmsrcimp.cxx
index af64411..5665f22 100644
--- a/svx/source/form/fmsrcimp.cxx
+++ b/svx/source/form/fmsrcimp.cxx
@@ -164,7 +164,7 @@ void FmRecordCountListener::NotifyCurrentCount()
if (m_lnkWhoWantsToKnow.IsSet())
{
DBG_ASSERT(m_xListening.is(), "FmRecordCountListener::NotifyCurrentCount : I have no propset ... !?");
- void* pTheCount = (void*)::comphelper::getINT32(m_xListening->getPropertyValue(FM_PROP_ROWCOUNT));
+ void* pTheCount = (void*)(sal_IntPtr)::comphelper::getINT32(m_xListening->getPropertyValue(FM_PROP_ROWCOUNT));
m_lnkWhoWantsToKnow.Call(pTheCount);
}
}
diff --git a/svx/source/gallery2/gallery1.cxx b/svx/source/gallery2/gallery1.cxx
index d03b67b..82d354a 100644
--- a/svx/source/gallery2/gallery1.cxx
+++ b/svx/source/gallery2/gallery1.cxx
@@ -94,25 +94,17 @@ INetURLObject GalleryThemeEntry::ImplGetURLIgnoreCase( const INetURLObject& rURL
{
INetURLObject aURL( rURL );
String aFileName;
- BOOL bExists = FALSE;
// check original file name
- if( FileExists( aURL ) )
- bExists = TRUE;
- else
+ if( !FileExists( aURL ) )
{
// check upper case file name
aURL.setName( aURL.getName().toAsciiUpperCase() );
- if( FileExists( aURL ) )
- bExists = TRUE;
- else
+ if(!FileExists( aURL ) )
{
// check lower case file name
aURL.setName( aURL.getName().toAsciiLowerCase() );
-
- if( FileExists( aURL ) )
- bExists = TRUE;
}
}
diff --git a/svx/source/stbctrls/modctrl.cxx b/svx/source/stbctrls/modctrl.cxx
index ca6cd0e..265804c 100644
--- a/svx/source/stbctrls/modctrl.cxx
+++ b/svx/source/stbctrls/modctrl.cxx
@@ -122,7 +122,6 @@ Point centerImage(const Rectangle& rBoundingRect, const Image& rImg)
}
void SvxModifyControl::Paint( const UserDrawEvent& rUsrEvt )
{
- const Rectangle aControlRect = getControlRect();
OutputDevice* pDev = rUsrEvt.GetDevice();
Rectangle aRect = rUsrEvt.GetRect();
diff --git a/svx/source/stbctrls/xmlsecctrl.cxx b/svx/source/stbctrls/xmlsecctrl.cxx
index 4667d17..0fc8151 100644
--- a/svx/source/stbctrls/xmlsecctrl.cxx
+++ b/svx/source/stbctrls/xmlsecctrl.cxx
@@ -147,8 +147,6 @@ void XmlSecStatusBarControl::Paint( const UserDrawEvent& rUsrEvt )
OutputDevice* pDev = rUsrEvt.GetDevice();
DBG_ASSERT( pDev, "-XmlSecStatusBarControl::Paint(): no Output Device... this will lead to nirvana..." );
Rectangle aRect = rUsrEvt.GetRect();
- StatusBar& rBar = GetStatusBar();
- Point aItemPos = rBar.GetItemTextPos( GetId() );
Color aOldLineColor = pDev->GetLineColor();
Color aOldFillColor = pDev->GetFillColor();
diff --git a/svx/source/svdraw/svdcrtv.cxx b/svx/source/svdraw/svdcrtv.cxx
index eb4be6e..c17133c 100644
--- a/svx/source/svdraw/svdcrtv.cxx
+++ b/svx/source/svdraw/svdcrtv.cxx
@@ -473,7 +473,6 @@ BOOL SdrCreateView::ImpBegCreateObj(UINT32 nInvent, UINT16 nIdent, const Point&
}
if (pAktCreate!=NULL)
{
- BOOL bStartEdit=FALSE; // nach Ende von Create automatisch TextEdit starten
if (pDefaultStyleSheet!=NULL) pAktCreate->NbcSetStyleSheet(pDefaultStyleSheet, sal_False);
// #101618# SW uses a naked SdrObject for frame construction. Normally, such an
@@ -492,8 +491,6 @@ BOOL SdrCreateView::ImpBegCreateObj(UINT32 nInvent, UINT16 nIdent, const Point&
aSet.Put(XFillStyleItem(XFILL_NONE));
pAktCreate->SetMergedItemSet(aSet);
-
- bStartEdit=TRUE;
}
if (nInvent==SdrInventor && (nIdent==OBJ_TEXT || nIdent==OBJ_TEXTEXT ||
nIdent==OBJ_TITLETEXT || nIdent==OBJ_OUTLINETEXT))
@@ -506,8 +503,6 @@ BOOL SdrCreateView::ImpBegCreateObj(UINT32 nInvent, UINT16 nIdent, const Point&
aSet.Put(XLineStyleItem(XLINE_NONE));
pAktCreate->SetMergedItemSet(aSet);
-
- bStartEdit=TRUE;
}
if (!rLogRect.IsEmpty()) pAktCreate->NbcSetLogicRect(rLogRect);
diff --git a/svx/source/tbxctrls/layctrl.cxx b/svx/source/tbxctrls/layctrl.cxx
index 390a5cd..262a285 100644
--- a/svx/source/tbxctrls/layctrl.cxx
+++ b/svx/source/tbxctrls/layctrl.cxx
@@ -307,7 +307,6 @@ void TableWindow::Paint( const Rectangle& )
aText += String(SVX_RESSTR(RID_SVXSTR_PAGES));
}
- Size aSize = GetOutputSizePixel();
Size aTextSize( GetTextWidth( aText ), GetTextHeight() );
long nTextX = nSelectionWidth + TABLE_CELL_WIDTH;
@@ -490,7 +489,6 @@ void ColumnsWindow::MouseMove( const MouseEvent& rMEvt )
SfxPopupWindow::MouseMove( rMEvt );
Point aPos = rMEvt.GetPosPixel();
Point aMousePos = aPos;
- Point aWinPos = GetPosPixel();
if ( rMEvt.IsEnterWindow() )
CaptureMouse();
More information about the Libreoffice-commits
mailing list