Added: openoffice/branches/sidebar/main/svx/source/sidebar/debug/ContextPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/debug/ContextPanel.hxx?rev=1457873&view=auto ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/debug/ContextPanel.hxx (added) +++ openoffice/branches/sidebar/main/svx/source/sidebar/debug/ContextPanel.hxx Mon Mar 18 17:14:04 2013 @@ -0,0 +1,56 @@ +/************************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + *************************************************************/ + +#ifndef SVX_SIDEBAR_DEBUG_CONTEXT_PANEL_HXX +#define SVX_SIDEBAR_DEBUG_CONTEXT_PANEL_HXX + +#include <sfx2/sidebar/IContextChangeReceiver.hxx> +#include <vcl/window.hxx> +#include <vcl/fixed.hxx> + + +namespace svx { namespace sidebar { + + +/** Display the current context. +*/ +class ContextPanel + : public Window, + public sfx2::sidebar::IContextChangeReceiver +{ +public: + ContextPanel (::Window* pParent); + virtual ~ContextPanel (void); + + // From Window + sal_Int32 GetPreferredHeight (sal_Int32 nWidth); + + // From IContextChangeReceiverInterface + virtual void HandleContextChange (const ::sfx2::sidebar::EnumContext aContext); + +private: + FixedText maApplicationName; + FixedText maContextName; +}; + +} } // end of namespace ::svx::sidebar + +#endif
Added: openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.cxx?rev=1457873&view=auto ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.cxx (added) +++ openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.cxx Mon Mar 18 17:14:04 2013 @@ -0,0 +1,49 @@ +/************************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + *************************************************************/ + +#include "precompiled_svx.hxx" + +#include "NotYetImplementedPanel.hxx" + +namespace svx { namespace sidebar { + +NotYetImplementedPanel::NotYetImplementedPanel (::Window* pParent) + : Window(pParent, 0), + maMessageControl(this, 0) +{ + maMessageControl.SetPosSizePixel(5,5, 250,15); + maMessageControl.SetText(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("not yet implemented"))); + + maMessageControl.Show(); + Show(); +} + + + + +NotYetImplementedPanel::~NotYetImplementedPanel (void) +{ +} + + + + +} } // end of namespace ::svx::sidebar Added: openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.hxx?rev=1457873&view=auto ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.hxx (added) +++ openoffice/branches/sidebar/main/svx/source/sidebar/debug/NotYetImplementedPanel.hxx Mon Mar 18 17:14:04 2013 @@ -0,0 +1,47 @@ +/************************************************************** + * + * Licensed to the Apache Software Foundation (ASF) under one + * or more contributor license agreements. See the NOTICE file + * distributed with this work for additional information + * regarding copyright ownership. The ASF licenses this file + * to you under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance + * with the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, + * software distributed under the License is distributed on an + * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY + * KIND, either express or implied. See the License for the + * specific language governing permissions and limitations + * under the License. + * + *************************************************************/ + +#ifndef SVX_SIDEBAR_DEBUG_NOT_YET_IMPLEMENTED_PANEL_HXX +#define SVX_SIDEBAR_DEBUG_NOT_YET_IMPLEMENTED_PANEL_HXX + +#include <vcl/window.hxx> +#include <vcl/fixed.hxx> + + +namespace svx { namespace sidebar { + + +/** Display a panel as placeholder for a not-yet-implemented panel. +*/ +class NotYetImplementedPanel + : public Window +{ +public: + NotYetImplementedPanel (::Window* pParent); + virtual ~NotYetImplementedPanel (void); + +private: + FixedText maMessageControl; +}; + +} } // end of namespace ::svx::sidebar + +#endif Modified: openoffice/branches/sidebar/main/svx/source/sidebar/graphic/GraphicPropertyPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/graphic/GraphicPropertyPanel.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/graphic/GraphicPropertyPanel.hxx (original) +++ openoffice/branches/sidebar/main/svx/source/sidebar/graphic/GraphicPropertyPanel.hxx Mon Mar 18 17:14:04 2013 @@ -25,24 +25,21 @@ #include <vcl/ctrl.hxx> #include <sfx2/sidebar/SidebarPanelBase.hxx> #include <sfx2/sidebar/ControllerItem.hxx> +#include <sfx2/sidebar/IContextChangeReceiver.hxx> #include <vcl/fixed.hxx> #include <boost/scoped_ptr.hpp> -////////////////////////////////////////////////////////////////////////////// -// pedefines class FixedText; class MetricField; class ListBox; class FloatingWindow; -////////////////////////////////////////////////////////////////////////////// -// namespace open namespace svx { namespace sidebar { class GraphicPropertyPanel : public Control, - public ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface, + public ::sfx2::sidebar::IContextChangeReceiver, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { public: @@ -128,14 +125,7 @@ private: void Initialize(); }; -////////////////////////////////////////////////////////////////////////////// -// namespace close -}} // end of namespace ::svx::sidebar +} } // end of namespace ::svx::sidebar -////////////////////////////////////////////////////////////////////////////// - -#endif // SVX_PROPERTYPANEL_GRAPHICPAGE_HXX - -////////////////////////////////////////////////////////////////////////////// -// eof +#endif Modified: openoffice/branches/sidebar/main/svx/source/sidebar/line/LinePropertyPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/line/LinePropertyPanel.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/line/LinePropertyPanel.hxx (original) +++ openoffice/branches/sidebar/main/svx/source/sidebar/line/LinePropertyPanel.hxx Mon Mar 18 17:14:04 2013 @@ -26,6 +26,7 @@ #include <vcl/ctrl.hxx> #include <sfx2/sidebar/SidebarPanelBase.hxx> #include <sfx2/sidebar/ControllerItem.hxx> +#include <sfx2/sidebar/IContextChangeReceiver.hxx> #include <vcl/fixed.hxx> #include <vcl/field.hxx> #include <boost/scoped_ptr.hpp> @@ -95,7 +96,7 @@ class LineWidthControl; class LinePropertyPanel : public Control, - public ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface, + public ::sfx2::sidebar::IContextChangeReceiver, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { private: Modified: openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.cxx (original) +++ openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.cxx Mon Mar 18 17:14:04 2013 @@ -281,9 +281,45 @@ void PosSizePropertyPanel::HandleContext maContext = aContext; - switch (maContext.GetCombinedContext()) + sal_Int32 nLayoutMode (0); + switch (maContext.GetCombinedContext_DI()) { - case CombinedEnumContext(Application_Writer, Context_Draw): //case PROPERTY_CONTEXT_SW_DRAW: + case CombinedEnumContext(Application_Writer, Context_Draw): + nLayoutMode = 0; + break; + + case CombinedEnumContext(Application_Writer, Context_Graphic): + case CombinedEnumContext(Application_Writer, Context_Media): + case CombinedEnumContext(Application_Writer, Context_Frame): + case CombinedEnumContext(Application_Writer, Context_OLE): + case CombinedEnumContext(Application_Writer, Context_Form): + nLayoutMode = 1; + break; + + case CombinedEnumContext(Application_Calc, Context_Draw): + case CombinedEnumContext(Application_Calc, Context_Graphic): + case CombinedEnumContext(Application_DrawImpress, Context_Draw): + case CombinedEnumContext(Application_DrawImpress, Context_TextObject): + case CombinedEnumContext(Application_DrawImpress, Context_Graphic): + nLayoutMode = 2; + break; + + case CombinedEnumContext(Application_Calc, Context_Chart): + case CombinedEnumContext(Application_Calc, Context_Form): + case CombinedEnumContext(Application_Calc, Context_Media): + case CombinedEnumContext(Application_Calc, Context_OLE): + case CombinedEnumContext(Application_Calc, Context_MultiObject): + case CombinedEnumContext(Application_DrawImpress, Context_Media): + case CombinedEnumContext(Application_DrawImpress, Context_Form): + case CombinedEnumContext(Application_DrawImpress, Context_OLE): + case CombinedEnumContext(Application_DrawImpress, Context_3DObject): + case CombinedEnumContext(Application_DrawImpress, Context_MultiObject): + nLayoutMode = 3; + break; + } + switch (nLayoutMode) + { + case 0: { mpMtrWidth->SetMin( 2 ); mpMtrHeight->SetMin( 2 ); @@ -322,11 +358,7 @@ void PosSizePropertyPanel::HandleContext } break; - case CombinedEnumContext(Application_Writer, Context_Graphic): //case PROPERTY_CONTEXT_SW_GRAPHIC: - case CombinedEnumContext(Application_Writer, Context_Media): //case PROPERTY_CONTEXT_SW_MEDIA: - case CombinedEnumContext(Application_Writer, Context_Frame): //case PROPERTY_CONTEXT_SW_FRAME: - case CombinedEnumContext(Application_Writer, Context_OLE): //case PROPERTY_CONTEXT_SW_OLE: - case CombinedEnumContext(Application_Writer, Context_Form): //case PROPERTY_CONTEXT_SW_FORM: + case 1: { mpMtrWidth->SetMin( 2 ); mpMtrHeight->SetMin( 2 ); @@ -356,11 +388,8 @@ void PosSizePropertyPanel::HandleContext SetSizePixel(aSize); } break; - case CombinedEnumContext(Application_Calc, Context_Draw): //case PROPERTY_CONTEXT_SC_DRAW: - case CombinedEnumContext(Application_Draw, Context_Draw): //case PROPERTY_CONTEXT_SD_DRAW: - case CombinedEnumContext(Application_Calc, Context_Graphic): //case PROPERTY_CONTEXT_SC_GRAPHIC: - case CombinedEnumContext(Application_Draw, Context_TextObject): //case PROPERTY_CONTEXT_SD_TEXTOBJ: - case CombinedEnumContext(Application_Draw, Context_Graphic): //case PROPERTY_CONTEXT_SD_GRAPHIC: + + case 2: { mpMtrWidth->SetMin( 1 ); mpMtrHeight->SetMin( 1 ); @@ -386,16 +415,8 @@ void PosSizePropertyPanel::HandleContext SetSizePixel(aSize); } break; - case CombinedEnumContext(Application_Calc, Context_Chart): //case PROPERTY_CONTEXT_SC_CHART: - case CombinedEnumContext(Application_Calc, Context_Form): //case PROPERTY_CONTEXT_SC_FORM: - case CombinedEnumContext(Application_Calc, Context_Media): //case PROPERTY_CONTEXT_SC_MEDIA: - case CombinedEnumContext(Application_Calc, Context_OLE): //case PROPERTY_CONTEXT_SC_OLE: - case CombinedEnumContext(Application_Calc, Context_Multiobj): //case PROPERTY_CONTEXT_SC_MULTIOBJ: - case CombinedEnumContext(Application_Draw, Context_Media): //case PROPERTY_CONTEXT_SD_MEDIA: - case CombinedEnumContext(Application_Draw, Context_Form): //case PROPERTY_CONTEXT_SD_FORM: - case CombinedEnumContext(Application_Draw, Context_OLE): //case PROPERTY_CONTEXT_SD_OLE: - case CombinedEnumContext(Application_Draw, Context_3DObj): //case PROPERTY_CONTEXT_SD_3DOBJ: - case CombinedEnumContext(Application_Draw, Context_Multiobj): //case PROPERTY_CONTEXT_SD_MULTIOBJ: + + case 3: { mpMtrWidth->SetMin( 1 ); mpMtrHeight->SetMin( 1 ); @@ -815,58 +836,64 @@ void PosSizePropertyPanel::NotifyItemUpd break; } - const sal_Int32 nCombinedContext(maContext.GetCombinedContext()); + const sal_Int32 nCombinedContext(maContext.GetCombinedContext_DI()); - if(1 == rMarkList.GetMarkCount()) - { - const SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj(); - const SdrObjKind eKind((SdrObjKind)pObj->GetObjIdentifier()); + switch (rMarkList.GetMarkCount()) + { + case 0: + break; - if(((nCombinedContext == CombinedEnumContext(Application_Draw, Context_Draw) // mnContextId == PROPERTY_CONTEXT_SD_DRAW - || nCombinedContext == CombinedEnumContext(Application_Draw, Context_TextObject) // mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ - ) && OBJ_EDGE == eKind) - || OBJ_CAPTION == eKind) - // if((((mnContextId == PROPERTY_CONTEXT_SD_DRAW) || (mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ)) && OBJ_EDGE == eKind) || OBJ_CAPTION == eKind) - { - mpFtAngle->Disable(); - mpMtrAngle->Disable(); - mpDial->Disable(); - mpFlipTbx->Disable(); - mpFtFlip->Disable(); - } - } - else - { - sal_uInt16 nMarkObj = 0; - bool isNoEdge = true; - while(rMarkList.GetMark(nMarkObj)) - { - const SdrObject* pObj = rMarkList.GetMark(nMarkObj)->GetMarkedSdrObj(); - const SdrObjKind eKind((SdrObjKind)pObj->GetObjIdentifier()); - - if(((nCombinedContext == CombinedEnumContext(Application_Draw, Context_Draw) // mnContextId == PROPERTY_CONTEXT_SD_DRAW - || nCombinedContext == CombinedEnumContext(Application_Draw, Context_TextObject) // mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ - ) && OBJ_EDGE == eKind) + case 1: + { + const SdrObject* pObj = rMarkList.GetMark(0)->GetMarkedSdrObj(); + const SdrObjKind eKind((SdrObjKind)pObj->GetObjIdentifier()); + + if(((nCombinedContext == CombinedEnumContext(Application_DrawImpress, Context_Draw) + || nCombinedContext == CombinedEnumContext(Application_DrawImpress, Context_TextObject) + ) && OBJ_EDGE == eKind) || OBJ_CAPTION == eKind) - // if((((mnContextId == PROPERTY_CONTEXT_SD_DRAW) || (mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ)) && OBJ_EDGE == eKind) ||OBJ_CAPTION == eKind) - { - isNoEdge = false; - break; - } - nMarkObj++; - } - if(!isNoEdge) - { - mpFtAngle->Disable(); - mpMtrAngle->Disable(); - mpDial->Disable(); - mpFlipTbx->Disable(); - mpFtFlip->Disable(); - } - } + { + mpFtAngle->Disable(); + mpMtrAngle->Disable(); + mpDial->Disable(); + mpFlipTbx->Disable(); + mpFtFlip->Disable(); + } + break; + } + + default: + { + sal_uInt16 nMarkObj = 0; + bool isNoEdge = true; + while(rMarkList.GetMark(nMarkObj)) + { + const SdrObject* pObj = rMarkList.GetMark(nMarkObj)->GetMarkedSdrObj(); + const SdrObjKind eKind((SdrObjKind)pObj->GetObjIdentifier()); + + if(((nCombinedContext == CombinedEnumContext(Application_DrawImpress, Context_Draw) + || nCombinedContext == CombinedEnumContext(Application_DrawImpress, Context_TextObject) + ) && OBJ_EDGE == eKind) + || OBJ_CAPTION == eKind) + { + isNoEdge = false; + break; + } + nMarkObj++; + } + if(!isNoEdge) + { + mpFtAngle->Disable(); + mpMtrAngle->Disable(); + mpDial->Disable(); + mpFlipTbx->Disable(); + mpFtFlip->Disable(); + } + break; + } + } - if(nCombinedContext == CombinedEnumContext(Application_Draw, Context_TextObject)) // mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ - //if(mnContextId == PROPERTY_CONTEXT_SD_TEXTOBJ) + if(nCombinedContext == CombinedEnumContext(Application_DrawImpress, Context_TextObject)) { mpFlipTbx->Disable(); mpFtFlip->Disable(); Modified: openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.hxx (original) +++ openoffice/branches/sidebar/main/svx/source/sidebar/possize/PosSizePropertyPanel.hxx Mon Mar 18 17:14:04 2013 @@ -25,6 +25,7 @@ #include <vcl/ctrl.hxx> #include <sfx2/sidebar/SidebarPanelBase.hxx> #include <sfx2/sidebar/ControllerItem.hxx> +#include <sfx2/sidebar/IContextChangeReceiver.hxx> #include <boost/scoped_ptr.hpp> #include <svx/rectenum.hxx> #include <svl/poolitem.hxx> @@ -45,7 +46,7 @@ class SidebarDialControl; class PosSizePropertyPanel : public Control, - public ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface, + public ::sfx2::sidebar::IContextChangeReceiver, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { public: Modified: openoffice/branches/sidebar/main/svx/source/sidebar/text/TextPropertyPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/svx/source/sidebar/text/TextPropertyPanel.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/svx/source/sidebar/text/TextPropertyPanel.hxx (original) +++ openoffice/branches/sidebar/main/svx/source/sidebar/text/TextPropertyPanel.hxx Mon Mar 18 17:14:04 2013 @@ -25,6 +25,7 @@ #include <vcl/ctrl.hxx> #include <sfx2/sidebar/SidebarPanelBase.hxx> #include <sfx2/sidebar/ControllerItem.hxx> +#include <sfx2/sidebar/IContextChangeReceiver.hxx> #include <svtools/ctrlbox.hxx> #include <svx/tbxcolorupdate.hxx> @@ -45,7 +46,7 @@ class SvxSBFontNameBox; class TextPropertyPanel : public Control, - public ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface, + public ::sfx2::sidebar::IContextChangeReceiver, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { public: Modified: openoffice/branches/sidebar/main/sw/inc/cmdid.h URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/inc/cmdid.h?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/inc/cmdid.h (original) +++ openoffice/branches/sidebar/main/sw/inc/cmdid.h Mon Mar 18 17:14:04 2013 @@ -64,7 +64,7 @@ Achtung: Ab sofort sind in diesem File k #define FN_EXTRA2 (SID_SW_START + 2200) #define FN_PARAM2 (SID_SW_START + 2400) #define FN_NOTES (SID_SW_START + 2500) -#define FN_SIDEBAR (SID_SW_START + 2550) +#define FN_SIDEBAR (SID_SW_START + 2550) /* More accurately, this range should be from FN_EXTRA2 to FN_PARAM2-1, but * FN_NUMBER_NEWSTART comes from FN_FORMAT2, and FN_PARAM_LINK_DISPLAY_NAME @@ -1265,6 +1265,9 @@ Achtung: Ab sofort sind in diesem File k #define FN_SIDEBAR_PROPERTY (FN_SIDEBAR) #define SID_ATTR_SWPAGE_COLUMN (FN_SIDEBAR_PROPERTY + 0) +#define FN_PROPERTY_SIDEBAR_GRAFIC_DLG (FN_SIDEBAR + 0) + + //Member-Ids fuer Fill/SetVariable an Items #define MID_STYLE 0xe0 #define MID_PWIDTH 0xe1 Modified: openoffice/branches/sidebar/main/sw/sdi/_grfsh.sdi URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/sdi/_grfsh.sdi?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/sdi/_grfsh.sdi (original) +++ openoffice/branches/sidebar/main/sw/sdi/_grfsh.sdi Mon Mar 18 17:14:04 2013 @@ -58,6 +58,12 @@ interface BaseTextGraphic StateMethod = GetAttrState ; DisableFlags="SW_DISABLE_ON_PROTECTED_CURSOR"; ] + FN_PROPERTY_SIDEBAR_GRAFIC_DLG // status(final|play) + [ + ExecMethod = Execute ; + StateMethod = GetAttrState ; + DisableFlags="SW_DISABLE_ON_PROTECTED_CURSOR"; + ] FN_SAVE_GRAPHIC // status(final|play) Modified: openoffice/branches/sidebar/main/sw/sdi/swriter.sdi URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/sdi/swriter.sdi?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/sdi/swriter.sdi (original) +++ openoffice/branches/sidebar/main/sw/sdi/swriter.sdi Mon Mar 18 17:14:04 2013 @@ -3459,6 +3459,30 @@ SfxVoidItem GraphicDialog FN_FORMAT_GRAF GroupId = GID_GRAPHIC; ] //-------------------------------------------------------------------------- +SfxVoidItem GraphicWrapDialog FN_PROPERTY_SIDEBAR_GRAFIC_DLG +() +[ + /* flags: */ + AutoUpdate = FALSE, + Cachable = Cachable, + FastCall = FALSE, + HasCoreId = FALSE, + HasDialog = TRUE, + ReadOnlyDoc = FALSE, + Toggle = FALSE, + Container = FALSE, + RecordAbsolute = FALSE, + RecordPerItem; + Asynchron; + + /* config: */ + AccelConfig = TRUE, + MenuConfig = TRUE, + StatusBarConfig = FALSE, + ToolBoxConfig = TRUE, + GroupId = GID_GRAPHIC; +] +//-------------------------------------------------------------------------- SfxVoidItem SaveGraphic FN_SAVE_GRAPHIC () [ Modified: openoffice/branches/sidebar/main/sw/source/core/doc/docdesc.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/core/doc/docdesc.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/core/doc/docdesc.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/core/doc/docdesc.cxx Mon Mar 18 17:14:04 2013 @@ -35,6 +35,8 @@ #include <tools/urlobj.hxx> #include <sfx2/docfile.hxx> #include <sfx2/printer.hxx> +#include <sfx2/bindings.hxx> +#include <sfx2/dispatch.hxx> #include <unotools/localedatawrapper.hxx> #include <com/sun/star/document/PrinterIndependentLayout.hpp> #include <fmtfsize.hxx> Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/annotsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/annotsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/annotsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/annotsh.cxx Mon Mar 18 17:14:04 2013 @@ -105,6 +105,7 @@ #include <svx/dialogs.hrc> #include <svx/svxids.hrc> +#include <sfx2/sidebar/EnumContext.hxx> #include <svl/itempool.hxx> #include <editeng/outliner.hxx> #include <editeng/editeng.hxx> @@ -151,6 +152,7 @@ SwAnnotationShell::SwAnnotationShell( Sw { SwWrtShell &rSh = rView.GetWrtShell(); SetPool(rSh.GetAttrPool().GetSecondaryPool()); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Annotation)); } SwAnnotationShell::~SwAnnotationShell() Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/beziersh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/beziersh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/beziersh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/beziersh.cxx Mon Mar 18 17:14:04 2013 @@ -31,6 +31,7 @@ #include <svl/eitem.hxx> #include <svl/whiter.hxx> #include <svx/svdopath.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <sfx2/request.hxx> #include <sfx2/dispatch.hxx> #include <sfx2/objface.hxx> @@ -73,6 +74,8 @@ SwBezierShell::SwBezierShell(SwView &_rV SwWrtShell *pSh = &GetShell(); SdrView* pSdrView = pSh->GetDrawView(); pSdrView->SetEliminatePolyPointLimitAngle(1500L); + + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Draw)); } /*-------------------------------------------------------------------- @@ -347,6 +350,3 @@ void SwBezierShell::GetState(SfxItemSet nWhich = aIter.NextWhich(); } } - - - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/drawsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/drawsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/drawsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/drawsh.cxx Mon Mar 18 17:14:04 2013 @@ -50,6 +50,7 @@ #include <com/sun/star/ui/dialogs/XExecutableDialog.hpp> #include <svx/xtable.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include "swundo.hxx" #include "wrtsh.hxx" @@ -388,6 +389,8 @@ SwDrawShell::SwDrawShell(SwView &_rView) { SetHelpId(SW_DRAWSHELL); SetName(String::CreateFromAscii("Draw")); + + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Draw)); } /************************************************************************* @@ -491,7 +494,3 @@ void SwDrawShell::GetFormTextState(SfxIt pDrView->GetAttributes( rSet ); } } - - - - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/drformsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/drformsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/drformsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/drformsh.cxx Mon Mar 18 17:14:04 2013 @@ -35,6 +35,7 @@ #include <sfx2/app.hxx> #include <sfx2/viewfrm.hxx> #include <sfx2/dispatch.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <svl/srchitem.hxx> #include <svx/fmglob.hxx> #include <svx/svdouno.hxx> @@ -262,11 +263,9 @@ SwDrawFormShell::SwDrawFormShell(SwView SetHelpId(SW_DRAWFORMSHELL); GetShell().NoEdit(sal_True); SetName(String::CreateFromAscii("DrawForm")); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Form)); } SwDrawFormShell::~SwDrawFormShell() { } - - - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/drwtxtsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/drwtxtsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/drwtxtsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/drwtxtsh.cxx Mon Mar 18 17:14:04 2013 @@ -43,6 +43,7 @@ #include <sfx2/bindings.hxx> #include <svx/fontwork.hxx> #include <sfx2/request.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <svl/whiter.hxx> #include <editeng/outliner.hxx> #include <editeng/editstat.hxx> @@ -159,6 +160,7 @@ SwDrawTextShell::SwDrawTextShell(SwView rSh.NoEdit(sal_True); SetName(String::CreateFromAscii("ObjectText")); SetHelpId(SW_DRWTXTSHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_DrawText)); } /*-------------------------------------------------------------------- @@ -903,6 +905,3 @@ void SwDrawTextShell::InsertSymbol(SfxRe pOutliner = pSdrView->GetTextEditOutliner(); return &pOutliner->GetUndoManager(); } - - - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/frmsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/frmsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/frmsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/frmsh.cxx Mon Mar 18 17:14:04 2013 @@ -42,6 +42,7 @@ #include <sfx2/dispatch.hxx> #include <sfx2/request.hxx> #include <sfx2/objface.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <svx/hlnkitem.hxx> // --> OD 2009-07-07 #i73249# #include <svx/svdview.hxx> @@ -906,6 +907,8 @@ SwFrameShell::SwFrameShell(SwView &_rVie /* #96392# Use this to announce it is the frame shell who creates the selection. */ SwTransferable::CreateSelection( _rView.GetWrtShell(), (ViewShell *) this ); + + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Frame)); } SwFrameShell::~SwFrameShell() @@ -1148,4 +1151,3 @@ void SwFrameShell::StateInsert(SfxItemS if ((nSel & nsSelectionType::SEL_GRF) || (nSel & nsSelectionType::SEL_OLE)) rSet.DisableItem(FN_INSERT_FRAME); } - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/grfsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/grfsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/grfsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/grfsh.cxx Mon Mar 18 17:14:04 2013 @@ -43,6 +43,7 @@ #include <editeng/sizeitem.hxx> #include <editeng/protitem.hxx> #include <sfx2/request.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <svl/srchitem.hxx> #include <svx/htmlmode.hxx> #include <svx/sdgluitm.hxx> @@ -113,6 +114,7 @@ void SwGrfShell::Execute(SfxRequest &rRe break; case SID_INSERT_GRAPHIC: case FN_FORMAT_GRAFIC_DLG: + case FN_PROPERTY_SIDEBAR_GRAFIC_DLG: { SwFlyFrmAttrMgr aMgr( sal_False, &rSh, rSh.IsFrmSelected() ? FRMMGR_TYPE_NONE : FRMMGR_TYPE_GRF); @@ -230,6 +232,10 @@ void SwGrfShell::Execute(SfxRequest &rRe GetView().GetWindow(), aSet, sal_False, DLG_FRM_GRF); DBG_ASSERT(pDlg, "Dialogdiet fail!"); + + if (nSlot == FN_PROPERTY_SIDEBAR_GRAFIC_DLG) + pDlg->SetCurPageId(TP_FRM_WRAP); + if( pDlg->Execute() ) { rSh.StartAllAction(); @@ -694,4 +700,5 @@ SwGrfShell::SwGrfShell(SwView &_rView) : { SetName(String::CreateFromAscii("Graphic")); SetHelpId(SW_GRFSHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Graphic)); } Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/mediash.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/mediash.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/mediash.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/mediash.cxx Mon Mar 18 17:14:04 2013 @@ -75,6 +75,7 @@ #endif #include <sfx2/objface.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <svx/svdomedia.hxx> #include <svx/sdr/contact/viewcontactofsdrmediaobj.hxx> #include <avmedia/mediaitem.hxx> @@ -215,4 +216,5 @@ SwMediaShell::SwMediaShell(SwView &_rVie { SetName(String::CreateFromAscii("Media Playback")); SetHelpId(SW_MEDIASHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Media)); } Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/olesh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/olesh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/olesh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/olesh.cxx Mon Mar 18 17:14:04 2013 @@ -29,6 +29,7 @@ #include <sfx2/request.hxx> #include <sfx2/objface.hxx> #include <sfx2/objitem.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <wrtsh.hxx> #include <view.hxx> #ifndef _HELPID_H @@ -71,6 +72,5 @@ SwOleShell::SwOleShell(SwView &_rView) : { SetName(String::CreateFromAscii("Object")); SetHelpId(SW_OLESHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_OLE)); } - - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/tabsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/tabsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/tabsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/tabsh.cxx Mon Mar 18 17:14:04 2013 @@ -54,6 +54,7 @@ #include <sfx2/request.hxx> #include <sfx2/dispatch.hxx> #include <sfx2/objface.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <fmtornt.hxx> @@ -1433,6 +1434,7 @@ SwTableShell::SwTableShell(SwView &_rVie { SetName(String::CreateFromAscii("Table")); SetHelpId(SW_TABSHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Table)); } /*-------------------------------------------------------------------- @@ -1591,4 +1593,3 @@ void SwTableShell::ExecNumberFormat(SfxR } } - Modified: openoffice/branches/sidebar/main/sw/source/ui/shells/textsh.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/shells/textsh.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/shells/textsh.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/shells/textsh.cxx Mon Mar 18 17:14:04 2013 @@ -108,6 +108,7 @@ #define TextFont #define DropCap #include <sfx2/msg.hxx> +#include <sfx2/sidebar/EnumContext.hxx> #include <swslots.hxx> #include <SwRewriter.hxx> #include <comcore.hrc> @@ -1027,6 +1028,7 @@ SwTextShell::SwTextShell(SwView &_rView) { SetName(String::CreateFromAscii("Text")); SetHelpId(SW_TEXTSHELL); + SfxShell::SetContextName(sfx2::sidebar::EnumContext::GetContextName(sfx2::sidebar::EnumContext::Context_Text)); } /*-------------------------------------------------------------------- @@ -1214,5 +1216,3 @@ void SwTextShell::InsertSymbol( SfxReque } } } - - Modified: openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageColumnControl.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageColumnControl.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageColumnControl.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageColumnControl.cxx Mon Mar 18 17:14:04 2013 @@ -29,6 +29,8 @@ #include <swtypes.hxx> #include <svx/sidebar/ValueSetWithTextControl.hxx> +#include <sfx2/bindings.hxx> +#include <sfx2/dispatch.hxx> namespace sw { namespace sidebar { Modified: openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageMarginControl.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageMarginControl.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageMarginControl.hxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageMarginControl.hxx Mon Mar 18 17:14:04 2013 @@ -26,8 +26,11 @@ #include <tools/fldunit.hxx> #include <svl/poolitem.hxx> +#include <svx/rulritem.hxx> #include <unotools/viewoptions.hxx> - +#include <vcl/fixed.hxx> +#include <vcl/field.hxx> +#include <svtools/unitconv.hxx> #include <vector> #define SWPAGE_NARROW_VALUE 720 Modified: openoffice/branches/sidebar/main/sw/source/ui/sidebar/PagePropertyPanel.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/sidebar/PagePropertyPanel.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/sidebar/PagePropertyPanel.hxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/sidebar/PagePropertyPanel.hxx Mon Mar 18 17:14:04 2013 @@ -24,7 +24,7 @@ #include <svx/sidebar/Popup.hxx> -#include <sfx2/sidebar/SidebarPanelBase.hxx> +#include <sfx2/sidebar/IContextChangeReceiver.hxx> #include <sfx2/sidebar/ControllerItem.hxx> namespace svx { namespace sidebar { @@ -34,6 +34,7 @@ namespace svx { namespace sidebar { #include <i18npool/paper.hxx> #include <svx/pageitem.hxx> +#include <svx/rulritem.hxx> #include <editeng/sizeitem.hxx> #include <vcl/ctrl.hxx> @@ -42,15 +43,20 @@ namespace svx { namespace sidebar { #include <vcl/toolbox.hxx> #include <vcl/lstbox.hxx> #include <vcl/field.hxx> +#include <svl/intitem.hxx> +#include <com/sun/star/frame/XFrame.hpp> #include <boost/scoped_ptr.hpp> +namespace css = ::com::sun::star; +namespace cssu = ::com::sun::star::uno; + namespace sw { namespace sidebar { class PagePropertyPanel : public Control, - public ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface, + public ::sfx2::sidebar::IContextChangeReceiver, public ::sfx2::sidebar::ControllerItem::ItemUpdateReceiverInterface { public: @@ -62,7 +68,7 @@ namespace sw { namespace sidebar { // override Window::DataChanged(..) inherited via Control to react on certain changes virtual void DataChanged( const DataChangedEvent& rEvent ); - // interface of ::sfx2::sidebar::SidebarPanelBase::ContextChangeReceiverInterface + // interface of ::sfx2::sidebar::IContextChangeReceiver virtual void HandleContextChange( const ::sfx2::sidebar::EnumContext aContext); Modified: openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.cxx Mon Mar 18 17:14:04 2013 @@ -31,6 +31,10 @@ #include <svx/sidebar/ValueSetWithTextControl.hxx> #include <tools/inetmime.hxx> +#include <editeng/paperinf.hxx> +#include <sfx2/bindings.hxx> +#include <sfx2/dispatch.hxx> + namespace sw { namespace sidebar { Modified: openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.hxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.hxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.hxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/sidebar/PageSizeControl.hxx Mon Mar 18 17:14:04 2013 @@ -27,6 +27,8 @@ #include <i18npool/paper.hxx> #include <vcl/button.hxx> +#include <vcl/field.hxx> +#include <svtools/unitconv.hxx> #include <vector> Modified: openoffice/branches/sidebar/main/sw/source/ui/uiview/view1.cxx URL: http://svn.apache.org/viewvc/openoffice/branches/sidebar/main/sw/source/ui/uiview/view1.cxx?rev=1457873&r1=1457872&r2=1457873&view=diff ============================================================================== --- openoffice/branches/sidebar/main/sw/source/ui/uiview/view1.cxx (original) +++ openoffice/branches/sidebar/main/sw/source/ui/uiview/view1.cxx Mon Mar 18 17:14:04 2013 @@ -134,10 +134,6 @@ void SwView::Activate(sal_Bool bMDIActiv AttrChangedNotify(pWrtShell); SfxViewShell::Activate(bMDIActivate); - - ContextChangeEventMultiplexer::NotifyContextChange( - GetController(), - ::sfx2::sidebar::EnumContext::Context_Default); } /*--------------------------------------------------------------------
