Kaydet (Commit) 160f62df authored tarafından Tomaž Vajngerl's avatar Tomaž Vajngerl

Svx and sw code cleanup

Change-Id: Ie93861f32ac23379dc1f0fd973612645e776cc1e
üst b9c37611
......@@ -216,7 +216,7 @@ public:
void FuTemporary(SfxRequest& rReq);
void FuPermanent(SfxRequest& rReq);
void FuSupport(SfxRequest& rReq);
void FuSupportRotate(SfxRequest& rReq);
void FuSupportRotate(SfxRequest& rReq);
void FuTable(SfxRequest& rReq);
void AttrExec (SfxRequest& rReq);
......
......@@ -714,23 +714,22 @@ void DrawViewShell::FuTemporary(SfxRequest& rReq)
{
WaitObject aWait( (Window*)GetActiveWindow() );
// switch on undo for the next operations
mpDrawView->BegUndo(
String(
SdResId (nSId==SID_CONVERT_TO_METAFILE ? STR_UNDO_CONVERT_TO_METAFILE : STR_UNDO_CONVERT_TO_BITMAP)));
// create SdrGrafObj from metafile/bitmap
Graphic aGraphic;
switch (nSId)
{
case SID_CONVERT_TO_METAFILE:
{
// switch on undo for the next operations
mpDrawView->BegUndo( String( SdResId( STR_UNDO_CONVERT_TO_METAFILE )));
GDIMetaFile aMetaFile(mpDrawView->GetAllMarkedMetaFile ());
aGraphic = Graphic(aMetaFile);
}
break;
case SID_CONVERT_TO_BITMAP:
{
// switch on undo for the next operations
mpDrawView->BegUndo( String( SdResId( STR_UNDO_CONVERT_TO_BITMAP )));
Bitmap aBitmap (mpDrawView->GetAllMarkedBitmap ());
aGraphic = Graphic(aBitmap);
}
......
......@@ -79,7 +79,7 @@ void SwReadOnlyPopup::Check( sal_uInt16 nMID, sal_uInt16 nSID, SfxDispatcher &rD
_pItem->ISA(SfxBoolItem) &&
((SfxBoolItem*)_pItem)->GetValue());
//remove full screen entry when not in full screen mode
if(SID_WIN_FULLSCREEN == nSID && !IsItemChecked(SID_WIN_FULLSCREEN) )
if( SID_WIN_FULLSCREEN == nSID && !IsItemChecked(SID_WIN_FULLSCREEN) )
EnableItem(nMID, sal_False);
}
}
......
......@@ -555,13 +555,10 @@ void SwGrfShell::GetAttrState(SfxItemSet &rSet)
bDisable = sal_True;
break;
case SID_SAVE_GRAPHIC:
if( rSh.GetGraphicType() == GRAPHIC_NONE )
bDisable = sal_True;
break;
case SID_EXTERNAL_EDIT:
if( rSh.GetGraphicType() == GRAPHIC_NONE )
bDisable = sal_True;
break;
break;
case SID_COLOR_SETTINGS:
{
if ( bParentCntProt || !bIsGrfCntnt )
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment