[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-04-18 Thread Andrzej Hunt
 sd/source/ui/remotecontrol/BluetoothServer.cxx  |  673 +---
 sd/source/ui/remotecontrol/BufferedStreamSocket.cxx |2 
 sd/source/ui/remotecontrol/Communicator.cxx |7 
 3 files changed, 609 insertions(+), 73 deletions(-)

New commits:
commit d92b1152cb4e700902288d5694add7154045140e
Author: Andrzej Hunt andrzej.h...@collabora.com
Date:   Thu Apr 10 21:58:29 2014 +0100

fdo#74697 Add Bluez 5 support for impress remote.

This time we:
 - Don't break SAL_WARN with an fprintf like syntax.
 - Replace DBUS_TYPE_UNIX_FD with it's definition 'h' as we might
   be building on dbus-glib versions that do not support it (however
   presumably anyone running bluez 5 will have a dbus version that is
   new enough to support this, i.e. purely a build-time issue).
 - Remove various C++11'isms.

Reviewed-on: https://gerrit.libreoffice.org/8924
Tested-by: Andrzej Hunt andrzej.h...@collabora.com
Reviewed-by: Andrzej Hunt andrzej.h...@collabora.com
(cherry picked from commit b15666fd7582729c75bd0dd1bd0cb5d7c5a77f0c)

Conflicts:
sd/source/ui/remotecontrol/BluetoothServer.cxx

Change-Id: I736cad2122cd3789a5c7fb62c39e409d41fc1e32
Reviewed-on: https://gerrit.libreoffice.org/8929
Reviewed-by: Caolán McNamara caol...@redhat.com
Tested-by: Caolán McNamara caol...@redhat.com

diff --git a/sd/source/ui/remotecontrol/BluetoothServer.cxx 
b/sd/source/ui/remotecontrol/BluetoothServer.cxx
index c87f1b8..0367b51 100644
--- a/sd/source/ui/remotecontrol/BluetoothServer.cxx
+++ b/sd/source/ui/remotecontrol/BluetoothServer.cxx
@@ -12,6 +12,8 @@
 #include iostream
 #include iomanip
 
+#include boost/scoped_ptr.hpp
+
 #include sal/log.hxx
 
 #ifdef LINUX_BLUETOOTH
@@ -89,25 +91,40 @@ struct DBusObject {
 }
 };
 
+static DBusObject* getBluez5Adapter(DBusConnection *pConnection);
+
 struct sd::BluetoothServer::Impl {
 // the glib mainloop running in the thread
 GMainContext *mpContext;
 DBusConnection *mpConnection;
 DBusObject *mpService;
 volatile bool mbExitMainloop;
+enum BluezVersion { BLUEZ4, BLUEZ5, UNKNOWN };
+BluezVersion maBluezVersion;
 
 Impl()
 : mpContext( g_main_context_new() )
 , mpConnection( NULL )
 , mpService( NULL )
 , mbExitMainloop( false )
+, maBluezVersion( UNKNOWN )
 { }
 
 DBusObject *getAdapter()
 {
-if( !mpService )
+if (mpService)
+{
+DBusObject* pAdapter = mpService-cloneForInterface( 
org.bluez.Adapter );
+return pAdapter;
+}
+else if (spServer-mpImpl-maBluezVersion == BLUEZ5)
+{
+return getBluez5Adapter(mpConnection);
+}
+else
+{
 return NULL;
-return mpService-cloneForInterface( org.bluez.Adapter );
+}
 }
 };
 
@@ -155,37 +172,181 @@ sendUnrefAndWaitForReply( DBusConnection *pConnection, 
DBusMessage *pMsg )
 return pMsg;
 }
 
+static bool
+isBluez5Available(DBusConnection *pConnection)
+{
+DBusMessage *pMsg;
+
+// Simplest wasy to check whether we have Bluez 5+ is to check
+// that we can obtain adapters using the new interfaces.
+// The first two error checks however don't tell us anything as they should
+// succeed as long as dbus is working correctly.
+pMsg = DBusObject( org.bluez, /, org.freedesktop.DBus.ObjectManager 
).getMethodCall( GetManagedObjects );
+if (!pMsg)
+{
+SAL_INFO(sdremote.bluetooth, No GetManagedObjects call created);
+return false;
+}
+
+pMsg = sendUnrefAndWaitForReply( pConnection, pMsg );
+if (!pMsg)
+{
+SAL_INFO(sdremote.bluetooth, No reply received);
+return false;
+}
+
+// If dbus is working correctly and we aren't on bluez 5 this is where we
+// should actually get the error.
+if (dbus_message_get_error_name( pMsg ))
+{
+SAL_INFO( sdremote.bluetooth, GetManagedObjects call failed with \
+ dbus_message_get_error_name( pMsg )
+ \ -- we don't seem to have Bluez 5 available);
+return false;
+}
+SAL_INFO(sdremote.bluetooth, GetManagedObjects call seems to have 
succeeded -- we must be on Bluez 5);
+dbus_message_unref(pMsg);
+return true;
+}
+
+
+static DBusObject*
+getBluez5Adapter(DBusConnection *pConnection)
+{
+DBusMessage *pMsg;
+// This returns a list of objects where we need to find the first
+// org.bluez.Adapter1 .
+pMsg = DBusObject( org.bluez, /, org.freedesktop.DBus.ObjectManager 
).getMethodCall( GetManagedObjects );
+if (!pMsg)
+return NULL;
+
+const gchar* pInterfaceType = org.bluez.Adapter1;
+
+pMsg = sendUnrefAndWaitForReply( pConnection, pMsg );
+
+DBusMessageIter aObjectIterator;
+if (pMsg  dbus_message_iter_init(pMsg, aObjectIterator))
+{
+if (DBUS_TYPE_ARRAY == 

[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-03-12 Thread Muthu Subramanian
 sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx |2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 2166db00d1d639b3a5032f1866a6c5cd7275e57d
Author: Muthu Subramanian sumu...@collabora.com
Date:   Wed Mar 12 12:31:52 2014 +0530

n#862516: Remember slides sorter view setting.

Keep the number of slides per row when moving across tabs.

Change-Id: I316dac87c9dc8c88149b510f93be88940d91d98c
Reviewed-on: https://gerrit.libreoffice.org/8542
Reviewed-by: Andras Timar andras.ti...@collabora.com
Tested-by: Andras Timar andras.ti...@collabora.com

diff --git a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx 
b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
index b32b4a2..6667c6c 100644
--- a/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
+++ b/sd/source/ui/slidesorter/shell/SlideSorterViewShell.cxx
@@ -593,6 +593,8 @@ void SlideSorterViewShell::Activate (sal_Bool 
bIsMDIActivate)
 
 void SlideSorterViewShell::Deactivate (sal_Bool /*bIsMDIActivate*/)
 {
+// Save Settings - Specifically SlidesPerRow to retrieve it later
+WriteFrameViewData();
 }
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-02-12 Thread Michael Stahl
 sd/source/ui/unoidl/sddetect.cxx |8 
 1 file changed, 8 insertions(+)

New commits:
commit 3bb16f0eeb7fc8fe0331e0aa11f65e2114928d09
Author: Michael Stahl mst...@redhat.com
Date:   Mon Feb 10 16:45:27 2014 +0100

fdo#73363: sd: fix mis-detection of Visio files as PPT

SdFilterDetect::detect() erroneously detects all binary MSO files, and
because the Visio types would be checked after PPT, Visio is pre-empted.

Change-Id: I6ec3647a508dc8d79b47bfff6de35ccae39416ee
(cherry picked from commit e62339f856efa0b8ef03df3bf8b93e098c4ac0d3)
Reviewed-on: https://gerrit.libreoffice.org/7977
Reviewed-by: Andras Timar andras.ti...@collabora.com
Tested-by: Andras Timar andras.ti...@collabora.com

diff --git a/sd/source/ui/unoidl/sddetect.cxx b/sd/source/ui/unoidl/sddetect.cxx
index 9e98a7b..66fab30 100644
--- a/sd/source/ui/unoidl/sddetect.cxx
+++ b/sd/source/ui/unoidl/sddetect.cxx
@@ -371,6 +371,10 @@ OUString SAL_CALL SdFilterDetect::detect( Sequence 
beans::PropertyValue  lDes
 else
 pFilter = SfxFilter::GetFilterByName( 
pFilterPowerPoint97);
 }
+else
+{
+pFilter = 0;
+}
 }
 else
 {
@@ -423,6 +427,10 @@ OUString SAL_CALL SdFilterDetect::detect( Sequence 
beans::PropertyValue  lDes
 }
 }
 }
+else
+{
+pFilter = 0;
+}
 }
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-02-06 Thread David Tardon
 sd/source/filter/ppt/pptinanimations.cxx |5 -
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit ad9fb2cbbb494a1b97ea493208b5264c3a2d98a5
Author: David Tardon dtar...@redhat.com
Date:   Thu Feb 6 15:16:27 2014 +0100

fdo#33852 do not remove too much from the path

Change-Id: I1cf89f300530e761df5a287097d05f95d8af2017
(cherry picked from commit eba6a6789c8832f961ac7054588ed84d04b65480)
Reviewed-on: https://gerrit.libreoffice.org/7900
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sd/source/filter/ppt/pptinanimations.cxx 
b/sd/source/filter/ppt/pptinanimations.cxx
index 75b426d..9011251 100644
--- a/sd/source/filter/ppt/pptinanimations.cxx
+++ b/sd/source/filter/ppt/pptinanimations.cxx
@@ -2128,7 +2128,10 @@ void AnimationImporter::importAnimateMotionContainer( 
const Atom* pAtom, const R
 OUString aStr;
 if ( aPath = aStr )
 {
-aStr = aStr.replace( 'E', ' ' );
+// E can appear inside a number, so we only check for 
its presence at the end
+aStr = aStr.trim();
+if (aStr.endsWith(E))
+aStr = aStr.copy(0, aStr.getLength() - 1);
 aStr = aStr.trim();
 aPath = aStr;
 xMotion-setPath( aPath );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-02-04 Thread Michael Meeks
 sd/source/ui/dlg/PaneDockingWindow.cxx |2 +-
 sd/source/ui/inc/PaneDockingWindow.hxx |5 -
 2 files changed, 1 insertion(+), 6 deletions(-)

New commits:
commit 7a3cac33e82a65cabae81e5bf8969c5c5853b3b2
Author: Michael Meeks michael.me...@collabora.com
Date:   Tue Feb 4 18:17:11 2014 +0100

fdo#74519 - don't drag around and use an uninitialized variable.

Change-Id: I08b43a6658a600398b434a0c90e0e16863402b33
Reviewed-on: https://gerrit.libreoffice.org/7857
Reviewed-by: Ahmad Harthi aalhar...@kacst.edu.sa
Tested-by: Ahmad Harthi aalhar...@kacst.edu.sa

diff --git a/sd/source/ui/dlg/PaneDockingWindow.cxx 
b/sd/source/ui/dlg/PaneDockingWindow.cxx
index fb81691..9136af9 100644
--- a/sd/source/ui/dlg/PaneDockingWindow.cxx
+++ b/sd/source/ui/dlg/PaneDockingWindow.cxx
@@ -109,7 +109,7 @@ void PaneDockingWindow::SetValidSizeRange (const Range 
aValidSizeRange)
 // to compensate the valid size range for that.
 const SvBorder aBorder (GetDecorationBorder());
 sal_Int32 nCompensation (pSplitWindow-IsHorizontal()
-? mnTitleBarHeight + aBorder.Top() + aBorder.Bottom()
+? aBorder.Top() + aBorder.Bottom()
 : aBorder.Left() + aBorder.Right());
 pSplitWindow-SetItemSizeRange(
 nSetId,
diff --git a/sd/source/ui/inc/PaneDockingWindow.hxx 
b/sd/source/ui/inc/PaneDockingWindow.hxx
index 7975225..5a8fc8d 100644
--- a/sd/source/ui/inc/PaneDockingWindow.hxx
+++ b/sd/source/ui/inc/PaneDockingWindow.hxx
@@ -69,11 +69,6 @@ public:
 Otherwise UnknownOrientation is returned.
 */
 Orientation GetOrientation (void) const;
-
-/** The current height of the title bar.
-*/
-sal_Int32 mnTitleBarHeight;
-
 };
 
 } // end of namespace ::sd
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-01-08 Thread Caolán McNamara
 sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx |   33 ++---
 sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx |   12 +--
 2 files changed, 38 insertions(+), 7 deletions(-)

New commits:
commit 152b0dd43165106f9c01bab33017e23dadf91fb6
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Dec 12 10:39:06 2013 +

fix occasional crash on dragging and dropping pages in slidesorters

pages go into the cache, and sometimes they get deleted before the
cache gets processed. Remove deleted pages when they go away

Change-Id: I291072a8541f4ca36979e9914975d81cc23a9497
(cherry picked from commit abe9d1463282690313aaf91d2a54011d10b900b9)
(cherry picked from commit 026e9335d792c6557255f064960e0ef6d28728e0)
Reviewed-on: https://gerrit.libreoffice.org/7053
Reviewed-by: David Tardon dtar...@redhat.com
Tested-by: David Tardon dtar...@redhat.com

diff --git a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx 
b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
index 835787b..cdc2b57 100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
@@ -94,6 +94,7 @@ RequestQueue::RequestQueue (const SharedCacheContext 
rpCacheContext)
 
 RequestQueue::~RequestQueue (void)
 {
+Clear();
 }
 
 
@@ -120,7 +121,15 @@ void RequestQueue::AddRequest (
 // order.
 sal_Int32 nPriority (mpCacheContext-GetPriority(aKey));
 Request aRequest (aKey, nPriority, eRequestClass);
-mpRequestQueue-insert(aRequest);
+
+std::pairContainer::iterator,bool ret = mpRequestQueue-insert(aRequest);
+bool bInserted = ret.second == true;
+
+if (bInserted)
+{
+SdrPage *pPage = const_castSdrPage*(aRequest.maKey);
+pPage-AddPageUser(*this);
+}
 
 SSCD_SET_REQUEST_CLASS(aKey,eRequestClass);
 
@@ -131,8 +140,11 @@ void RequestQueue::AddRequest (
 #endif
 }
 
-
-
+void RequestQueue::PageInDestruction(const SdrPage rPage)
+{
+//remove any requests pending for this page which is going away now
+RemoveRequest(rPage);
+}
 
 bool RequestQueue::RemoveRequest (
 CacheKey aKey)
@@ -152,7 +164,11 @@ bool RequestQueue::RemoveRequest (
 mnMinimumPriority++;
 else if (aRequestIterator-mnPriorityInClass == 
mnMaximumPriority-1)
 mnMaximumPriority--;
+
+SdrPage *pPage = const_castSdrPage*(aRequestIterator-maKey);
+pPage-RemovePageUser(*this);
 mpRequestQueue-erase(aRequestIterator);
+
 bRequestWasRemoved = true;
 
 if (bRequestWasRemoved)
@@ -229,7 +245,10 @@ void RequestQueue::PopFront (void)
 {
 SSCD_SET_STATUS(maRequestQueue.begin()-mpData-GetPage(),NONE);
 
-mpRequestQueue-erase(mpRequestQueue-begin());
+Container::const_iterator aIter(mpRequestQueue-begin());
+SdrPage *pPage = const_castSdrPage*(aIter-maKey);
+pPage-RemovePageUser(*this);
+mpRequestQueue-erase(aIter);
 
 // Reset the priority counter if possible.
 if (mpRequestQueue-empty())
@@ -256,6 +275,12 @@ void RequestQueue::Clear (void)
 {
 ::osl::MutexGuard aGuard (maMutex);
 
+for (Container::iterator aI = mpRequestQueue-begin(), aEnd = 
mpRequestQueue-end(); aI != aEnd; ++aI)
+{
+SdrPage *pPage = const_castSdrPage*(aI-maKey);
+pPage-RemovePageUser(*this);
+}
+
 mpRequestQueue-clear();
 mnMinimumPriority = 0;
 mnMaximumPriority = 1;
diff --git a/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx 
b/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
index 78a4627..088a135 100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestQueue.hxx
@@ -24,7 +24,8 @@
 #include cache/SlsCacheContext.hxx
 #include taskpane/SlideSorterCacheDisplay.hxx
 #include drawdoc.hxx
-#include osl/mutex.hxx
+#include osl/mutex.hxx
+#include svx/sdrpageuser.hxx
 
 
 namespace sd { namespace slidesorter { namespace cache {
@@ -34,11 +35,11 @@ class RequestData;
 /** The request queue stores requests that are described by the RequestData
 sorted according to priority class and then priority.
 */
-class RequestQueue
+class RequestQueue : public sdr::PageUser
 {
 public:
 RequestQueue (const SharedCacheContext rpCacheContext);
-~RequestQueue (void);
+virtual ~RequestQueue();
 
 /** Insert a request with highest or lowest priority in its priority
 class.  When the request is already present then it is first
@@ -99,6 +100,11 @@ public:
 */
 ::osl::Mutex GetMutex (void);
 
+/** Ensure we don't hand out a page deleted before anyone got a
+chance to process it
+*/
+virtual void PageInDestruction(const SdrPage rPage);
+
 private:
 ::osl::Mutex maMutex;
 class Container;
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org

[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2014-01-06 Thread Caolán McNamara
 sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx |   11 ---
 1 file changed, 8 insertions(+), 3 deletions(-)

New commits:
commit 6a7a73d278c300ac7519d1ec50e5a4495f174f89
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Dec 12 12:37:43 2013 +

pages with equal Priority and Class getting dropped

Change-Id: Ib053dc4b6e5fb5f01f48c71a4b295a53c0ec6715
(cherry picked from commit 9790588da4b2de455ffc7a2cc69f26539823c3da)
(cherry picked from commit be366ad7690b190c5ef4dc42311a4df6b7dcce4b)
Reviewed-on: https://gerrit.libreoffice.org/7054
Reviewed-by: Stephan Bergmann sberg...@redhat.com
Tested-by: Stephan Bergmann sberg...@redhat.com

diff --git a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx 
b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
index d02bae1..835787b 100644
--- a/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
+++ b/sd/source/ui/slidesorter/cache/SlsRequestQueue.cxx
@@ -40,9 +40,14 @@ public:
 bool operator() (const Request rRequest1, const Request rRequest2)
 {
 if (rRequest1.meClass == rRequest2.meClass)
-return (rRequest1.mnPriorityInClass  
rRequest2.mnPriorityInClass);
-else
-return (rRequest1.meClass  rRequest2.meClass);
+{
+if (rRequest1.mnPriorityInClass == rRequest2.mnPriorityInClass)
+{
+return rRequest1.maKey  rRequest2.maKey;
+}
+return rRequest1.mnPriorityInClass  
rRequest2.mnPriorityInClass;
+}
+return rRequest1.meClass  rRequest2.meClass;
 }
 };
 /** Request data is compared arbitrarily by their addresses in memory.
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source sd/uiconfig

2013-12-05 Thread Rob Snelders
 sd/source/ui/view/drvwshrg.cxx   |1 +
 sd/uiconfig/simpress/menubar/menubar.xml |1 +
 2 files changed, 2 insertions(+)

New commits:
commit cb4225144f1fff44f9bb972fe06f51524da11b8b
Author: Rob Snelders programm...@ertai.nl
Date:   Thu Dec 5 23:56:52 2013 +0100

Partly revert Resolves: #ii122335# Disabling the old task pane

This partly reverts commit 95ae39c0c34c9a5e6fa6e72bf3a631a9a799b872.

SideBar is experimental, Impress still needs the TaskPane slot, otherwise 
once
disabled / clicked away the user won't get the TaskPane back.

Change-Id: I65b9e4a52ef2f3f1e7240fc01b828d2ff5d1589c
Reviewed-on: https://gerrit.libreoffice.org/6943
Reviewed-by: Eike Rathke er...@redhat.com
Tested-by: Eike Rathke er...@redhat.com

diff --git a/sd/source/ui/view/drvwshrg.cxx b/sd/source/ui/view/drvwshrg.cxx
index bb20370..c71959c 100644
--- a/sd/source/ui/view/drvwshrg.cxx
+++ b/sd/source/ui/view/drvwshrg.cxx
@@ -94,6 +94,7 @@ SFX_IMPL_INTERFACE(GraphicViewShell, SfxShell, 
SdResId(STR_DRAWVIEWSHELL)) //SOH
 {
 SFX_POPUPMENU_REGISTRATION( SdResId(RID_DRAW_TEXTOBJ_INSIDE_POPUP) );
 SFX_CHILDWINDOW_CONTEXT_REGISTRATION( SID_NAVIGATOR );
+SFX_CHILDWINDOW_REGISTRATION( SID_TASKPANE );
 SFX_CHILDWINDOW_REGISTRATION( SfxTemplateDialogWrapper::GetChildWindowId() 
);
 SFX_CHILDWINDOW_REGISTRATION( SvxFontWorkChildWindow::GetChildWindowId() );
 SFX_CHILDWINDOW_REGISTRATION( SvxColorChildWindow::GetChildWindowId() );
diff --git a/sd/uiconfig/simpress/menubar/menubar.xml 
b/sd/uiconfig/simpress/menubar/menubar.xml
index 9ad2019..9a5b874 100644
--- a/sd/uiconfig/simpress/menubar/menubar.xml
+++ b/sd/uiconfig/simpress/menubar/menubar.xml
@@ -113,6 +113,7 @@
 /menu:menupopup
 /menu:menu
 menu:menuseparator/
+  menu:menuitem menu:id=.uno:TaskPane/
   menu:menuitem menu:id=.uno:Sidebar/
   menu:menuitem menu:id=.uno:LeftPaneImpress/
 menu:menuitem menu:id=.uno:AvailableToolbars/
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source vcl/source

2013-11-18 Thread Caolán McNamara
 sd/source/filter/eppt/epptbase.hxx|3 ++
 sd/source/filter/eppt/pptx-stylesheet.cxx |4 +-
 sd/source/filter/eppt/pptx-text.cxx   |   41 ++
 sd/source/filter/eppt/text.hxx|   28 +---
 vcl/source/filter/wmf/emfwr.cxx   |   19 +
 5 files changed, 62 insertions(+), 33 deletions(-)

New commits:
commit 82bce2c10fe5718a3a51125ce0c284c13315d00d
Author: Caolán McNamara caol...@redhat.com
Date:   Fri Nov 15 17:06:21 2013 +

Related: rhbz#1014990 valgrind reports uninitialized variable

(cherry picked from commit f3660062ce8a2c65d483b83c2800d9b958d12f08)

Conflicts:
sd/source/filter/eppt/epptbase.hxx

Change-Id: Ibaa2ed0ee2f1f3f00bceec91ccced968e4913e47

Related: rhbz#1014990 valgrind reports uninitialized another variable

Change-Id: I77f082ea145b0f20daa93c3ee04067ecb6c3b108
(cherry picked from commit b7069ad07dc651f5326cd3a671588d8c1ecf2534)

Related: rhbz#1014990 valgrind reports yet another uninitialized variable

Change-Id: Idf15ee825a34aa7788c422475aa6cea8ff802581
(cherry picked from commit e0840f70565062b712e544f952640ee35cfb6a27)

Related: rhbz#1014990 valgrind reports yet another unint variable

Change-Id: Idf6a0a1e12fffee6c090add41247723f1d9cf576
(cherry picked from commit b211b8b2e14bd961a7b32033468a94cbff52b5c4)
Reviewed-on: https://gerrit.libreoffice.org/6712
Reviewed-by: Michael Stahl mst...@redhat.com
Tested-by: Michael Stahl mst...@redhat.com

diff --git a/sd/source/filter/eppt/epptbase.hxx 
b/sd/source/filter/eppt/epptbase.hxx
index f84360d..2566b98 100644
--- a/sd/source/filter/eppt/epptbase.hxx
+++ b/sd/source/filter/eppt/epptbase.hxx
@@ -157,6 +157,9 @@ struct FontCollectionEntry
 
 FontCollectionEntry( const String rName ) :
 Scaling ( 1.0 ),
+Family  ( 0 ),
+Pitch   ( 0 ),
+CharSet ( 0 ),
 Original( rName )
 {
 ImplInit( rName );
diff --git a/sd/source/filter/eppt/pptx-stylesheet.cxx 
b/sd/source/filter/eppt/pptx-stylesheet.cxx
index d9fd8fd..24e98f1 100644
--- a/sd/source/filter/eppt/pptx-stylesheet.cxx
+++ b/sd/source/filter/eppt/pptx-stylesheet.cxx
@@ -286,8 +286,8 @@ void PPTExParaSheet::SetStyleSheet( const 
::com::sun::star::uno::Reference ::co
 
 if ( !nLevel )
 {
-if ( ( aParagraphObj.meBullet ==  
::com::sun::star::beans::PropertyState_DIRECT_VALUE )
- aParagraphObj.bExtendedParameters )
+if (aParagraphObj.bExtendedParameters 
+ aParagraphObj.meBullet == 
::com::sun::star::beans::PropertyState_DIRECT_VALUE)
 {
 for ( sal_Int16 i = 0; i  5; i++ )
 {
diff --git a/sd/source/filter/eppt/pptx-text.cxx 
b/sd/source/filter/eppt/pptx-text.cxx
index adadc44..cc0c769 100644
--- a/sd/source/filter/eppt/pptx-text.cxx
+++ b/sd/source/filter/eppt/pptx-text.cxx
@@ -628,10 +628,21 @@ PortionObj PortionObj::operator=( const PortionObj 
rPortionObj )
 return *this;
 }
 
-ParagraphObj::ParagraphObj( const ::com::sun::star::uno::Reference 
::com::sun::star::beans::XPropertySet   rXPropSet,
-PPTExBulletProvider rProv ) :
-maMapModeSrc( MAP_100TH_MM ),
-maMapModeDest   ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 
576 ) )
+ParagraphObj::ParagraphObj(const ::com::sun::star::uno::Reference 
::com::sun::star::beans::XPropertySet   rXPropSet,
+PPTExBulletProvider rProv)
+: maMapModeSrc(MAP_100TH_MM)
+, maMapModeDest(MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 576 ))
+, mnTextSize(0)
+, mbFirstParagraph(false)
+, mbLastParagraph(false)
+, mnTextAdjust(0)
+, mnLineSpacing(0)
+, mbFixedLineSpacing(false)
+, mnLineSpacingTop(0)
+, mnLineSpacingBottom(0)
+, mbForbiddenRules(false)
+, mbParagraphPunctation(false)
+, mnBiDi(0)
 {
 mXPropSet = rXPropSet;
 
@@ -644,12 +655,22 @@ ParagraphObj::ParagraphObj( const 
::com::sun::star::uno::Reference ::com::sun::
 ImplGetParagraphValues( rProv, sal_False );
 }
 
-ParagraphObj::ParagraphObj( ::com::sun::star::uno::Reference 
::com::sun::star::text::XTextContent   rXTextContent,
-ParaFlags aParaFlags, FontCollection rFontCollection, 
PPTExBulletProvider rProv ) :
-maMapModeSrc( MAP_100TH_MM ),
-maMapModeDest   ( MAP_INCH, Point(), Fraction( 1, 576 ), Fraction( 1, 
576 ) ),
-mbFirstParagraph( aParaFlags.bFirstParagraph ),
-mbLastParagraph ( aParaFlags.bLastParagraph )
+ParagraphObj::ParagraphObj(::com::sun::star::uno::Reference 
::com::sun::star::text::XTextContent   rXTextContent,
+ParaFlags aParaFlags, FontCollection rFontCollection, 
PPTExBulletProvider rProv )
+: maMapModeSrc(MAP_100TH_MM)
+  

[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-11-13 Thread Caolán McNamara
 sd/source/ui/inc/slideshow.hxx |5 ++
 sd/source/ui/slideshow/slideshowimpl.cxx   |6 +-
 sd/source/ui/slideshow/slideshowimpl.hxx   |2 
 sd/source/ui/slidesorter/controller/SlsSlotManager.cxx |   29 
 sd/source/ui/view/drviewse.cxx |   40 +++--
 sd/source/ui/view/outlnvs2.cxx |   30 
 6 files changed, 39 insertions(+), 73 deletions(-)

New commits:
commit 393c38129284fe3b9b9fc0b927f8cd128f016a86
Author: Caolán McNamara caol...@redhat.com
Date:   Tue Oct 22 12:20:16 2013 +0100

Resolves: fdo#69975 honour custom show settings

if a custom show is set, then don't override it with
current/first page, just accept it

Change-Id: Icd04711028b3e11a576df6cd325ddb0db8974111
(cherry picked from commit 438f5cf4229dafe2100e36d818b05535091054d7)

merge all three ShowSlideShow impls together

Change-Id: If82f6313b258a79d59fbe34ab7846db5f9f45f76
(cherry picked from commit 368e94ce33bb4de1d2c0348082a349331a17f332)

bStartWithActualSlide is always false

(cherry picked from commit a1b0b68c0f1fe2467cddf021e09123085d043de2)

Conflicts:
sd/source/ui/slideshow/slideshowimpl.cxx
sd/source/ui/slideshow/slideshowimpl.hxx

Change-Id: Icf61858730e2576439fdc7bdd1c8a911f2b34bd7
Reviewed-on: https://gerrit.libreoffice.org/6374
Reviewed-by: David Tardon dtar...@redhat.com
Tested-by: David Tardon dtar...@redhat.com

diff --git a/sd/source/ui/inc/slideshow.hxx b/sd/source/ui/inc/slideshow.hxx
index a309c82..be44a51 100644
--- a/sd/source/ui/inc/slideshow.hxx
+++ b/sd/source/ui/inc/slideshow.hxx
@@ -214,6 +214,11 @@ private:
 sal_Int32   mnInPlaceConfigEvent;
 };
 
+namespace slideshowhelp
+{
+void ShowSlideShow(SfxRequest rReq, SdDrawDocument rDoc);
+}
+
 }
 
 #endif /* _SD_SLIDESHOW_HXX */
diff --git a/sd/source/ui/slideshow/slideshowimpl.cxx 
b/sd/source/ui/slideshow/slideshowimpl.cxx
index b096dc4..6fbd862 100644
--- a/sd/source/ui/slideshow/slideshowimpl.cxx
+++ b/sd/source/ui/slideshow/slideshowimpl.cxx
@@ -974,7 +974,7 @@ bool SlideshowImpl::startShow( PresentationSettingsEx* 
pPresSettings )
 }
 
 // build page list
-createSlideList( maPresSettings.mbAll, false, aPresSlide );
+createSlideList( maPresSettings.mbAll, aPresSlide );
 
 // remember Slide number from where the show was started
 if( pStartPage )
@@ -2449,7 +2449,7 @@ Reference XSlideShow  SlideshowImpl::createSlideShow() 
const
 
 // -
 
-void SlideshowImpl::createSlideList( bool bAll, bool bStartWithActualSlide, 
const String rPresSlide )
+void SlideshowImpl::createSlideList( bool bAll, const String rPresSlide )
 {
 const long nSlideCount = mpDoc-GetSdPageCount( PK_STANDARD );
 
@@ -2457,7 +2457,7 @@ void SlideshowImpl::createSlideList( bool bAll, bool 
bStartWithActualSlide, cons
 {
 SdCustomShow*   pCustomShow;
 
-if( !bStartWithActualSlide  mpDoc-GetCustomShowList()  
maPresSettings.mbCustomShow )
+if( mpDoc-GetCustomShowList()  maPresSettings.mbCustomShow )
 pCustomShow = mpDoc-GetCustomShowList()-GetCurObject();
 else
 pCustomShow = NULL;
diff --git a/sd/source/ui/slideshow/slideshowimpl.hxx 
b/sd/source/ui/slideshow/slideshowimpl.hxx
index 8be006b..89db0b2 100644
--- a/sd/source/ui/slideshow/slideshowimpl.hxx
+++ b/sd/source/ui/slideshow/slideshowimpl.hxx
@@ -265,7 +265,7 @@ private:
 
 double update();
 
-void createSlideList( bool bAll, bool bStartWithActualSlide, const String 
rPresSlide );
+void createSlideList( bool bAll, const String rPresSlide );
 
 void displayCurrentSlide (const bool bSkipAllMainSequenceEffects = false);
 
diff --git a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx 
b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
index 6b9c690..ecb7761 100644
--- a/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSlotManager.cxx
@@ -883,34 +883,7 @@ void SlotManager::GetStatusBarState (SfxItemSet rSet)
 
 void SlotManager::ShowSlideShow( SfxRequest rReq)
 {
-Reference XPresentation2  xPresentation( 
mrSlideSorter.GetModel().GetDocument()-getPresentation() );
-if( xPresentation.is() )
-{
-if( ( SID_REHEARSE_TIMINGS != rReq.GetSlot() ) )
-{
-if( (SID_PRESENTATION == rReq.GetSlot() ) )
-{
-Sequence PropertyValue  aArguments(1);
-PropertyValue aPage;
-OUString sValue(0);
-
-aPage.Name = FirstPage;
-aPage.Value = sValue;
-
-aArguments[0] = aPage;
-
-xPresentation-startWithArguments( aArguments );
-}
-else
-{
-xPresentation-start();
-

[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-10-11 Thread Armin Le Grand
 sd/source/ui/table/tablefunction.cxx |9 +
 1 file changed, 9 insertions(+)

New commits:
commit 888007f5850b997b2bbf4d1b7615a536140e72e8
Author: Armin Le Grand a...@apache.org
Date:   Wed Oct 9 15:31:38 2013 +

Resolves: #i123359# need to call SdrEndTextEdit before...

manipulating objects at model/view

(cherry picked from commit b5e8564995cd92e19cadcf8a6e9151be3efeeff4)

Change-Id: Ie282370c7fc2dea4f9d59d85aac742b41d7c4541
(cherry picked from commit 668730fbdd1ccf9a23d0a55361d019ca9e58ff39)

diff --git a/sd/source/ui/table/tablefunction.cxx 
b/sd/source/ui/table/tablefunction.cxx
index 77de56c..1ab6f9b 100644
--- a/sd/source/ui/table/tablefunction.cxx
+++ b/sd/source/ui/table/tablefunction.cxx
@@ -161,6 +161,15 @@ void DrawViewShell::FuTable(SfxRequest rReq)
 apply_table_style( pObj, GetDoc(), sTableStyle );
 SdrPageView* pPV = mpView-GetSdrPageView();
 
+// #i123359# if an object is to be replaced/manipulated it may be that 
it is in text edit mode,
+// so to be on the safe side call SdrEndTextEdit here
+SdrTextObj* pCheckForTextEdit = dynamic_cast SdrTextObj* (pPickObj);
+
+if(pCheckForTextEdit  pCheckForTextEdit-IsInEditMode())
+{
+mpView-SdrEndTextEdit();
+}
+
 // if we have a pick obj we need to make this new ole a pres obj 
replacing the current pick obj
 if( pPickObj )
 {
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-08-19 Thread Michael Meeks
 sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx |3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 6ce6b25ef4fbca3dae71b40e07176b0eeb8e1ca7
Author: Michael Meeks michael.me...@suse.com
Date:   Sat Aug 3 13:35:19 2013 +0200

fdo#67707 - avoid crash with sidebar when switching to writer from impress.

Change-Id: I0010663951fe67bfb864ffdaecb251b3da5a3ac3
(cherry picked from commit 457bc1ebdf327685fcf2ccac8d6c87c839c43200)
Reviewed-on: https://gerrit.libreoffice.org/5516
Tested-by: Michael Meeks michael.me...@suse.com
Reviewed-by: Michael Meeks michael.me...@suse.com

diff --git a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx 
b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
index ca0ff0b..c1b1e1a 100644
--- a/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsSelectionFunction.cxx
@@ -17,7 +17,6 @@
  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
  */
 
-
 #include controller/SlsSelectionFunction.hxx
 
 #include SlideSorter.hxx
@@ -439,7 +438,7 @@ sal_Bool SelectionFunction::KeyInput (const KeyEvent 
rEvent)
 mpModeHandler-SetCurrentPage(pDescriptor);
 mpModeHandler-SwitchView(pDescriptor);
 }
-else
+else if (pViewShell-GetDispatcher() != NULL)
 {
 pViewShell-GetDispatcher()-Execute(
 SID_INSERTPAGE,
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-07-19 Thread Caolán McNamara
 sd/source/ui/view/drviews1.cxx |4 ++--
 sd/source/ui/view/outlnvsh.cxx |1 +
 sd/source/ui/view/viewshel.cxx |3 +--
 3 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit 07cd8dd444620012d843b785c2243029a6d99944
Author: Caolán McNamara caol...@redhat.com
Date:   Thu Jul 18 14:27:15 2013 +0100

Resolves: fdo#66924 switching to master view is broken

It seems 0143805a565418d2a114c16b7eeba3b784176d9e wanted to not call
SfxShell::Activate from ViewShell::Activate and removed that call and added 
an
explicit SfxShell::BroadcastContextForActivation(true) (which is the body of
SfxShell::Activate) to OutlineViewShell::Activate for the case where it was
apparently wanted.

Then DrawViewShell::Deactivate had the call to ViewShell::Deactivate removed
persumably to avoid calling SfxShell::Deactivate via ViewShell::Deactivate

But with ViewShell::Deactivate omitted switching to master view is broken, 
it
does quite a lot more than call just SfxShell::Deactivate

Restore the call of ViewShell::Deactivate from DrawViewShell::Deactivate and
remove the call of SfxShell::Deactivate from ViewShell::Deactivate and put 
its
equivalent of SfxShell::BroadcastContextForActivation(false) into
OutlineViewShell::Deactivate to balance OutlineViewShell::Activate

regression since 0143805a565418d2a114c16b7eeba3b784176d9e

Change-Id: I5175378af6a6527a8be4d5011f13029d028b4304
(cherry picked from commit 4a578dc9c7b9c5697f624807790565c99ccb919d)
Reviewed-on: https://gerrit.libreoffice.org/4974
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sd/source/ui/view/drviews1.cxx b/sd/source/ui/view/drviews1.cxx
index 26ad764..e6ea485 100644
--- a/sd/source/ui/view/drviews1.cxx
+++ b/sd/source/ui/view/drviews1.cxx
@@ -114,9 +114,9 @@ void DrawViewShell::UIDeactivated( SfxInPlaceClient* pCli )
 }
 
 
-void DrawViewShell::Deactivate(sal_Bool /*bIsMDIActivate*/)
+void DrawViewShell::Deactivate(sal_Bool bIsMDIActivate)
 {
-// Do not forward to ViewShell::Deactivate() to prevent a context change.
+ViewShell::Deactivate(bIsMDIActivate);
 }
 
 namespace
diff --git a/sd/source/ui/view/outlnvsh.cxx b/sd/source/ui/view/outlnvsh.cxx
index 80f8b3d..446c31f 100644
--- a/sd/source/ui/view/outlnvsh.cxx
+++ b/sd/source/ui/view/outlnvsh.cxx
@@ -383,6 +383,7 @@ void OutlineViewShell::Deactivate( sal_Bool bIsMDIActivate )
 // Links must be kept also on deactivated viewshell, to allow drag'n'drop
 // to function properly
 ViewShell::Deactivate( bIsMDIActivate );
+SfxShell::BroadcastContextForActivation(false);
 }
 
 /**
diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx
index 19ab220..2117370 100644
--- a/sd/source/ui/view/viewshel.cxx
+++ b/sd/source/ui/view/viewshel.cxx
@@ -403,8 +403,7 @@ void ViewShell::Deactivate(sal_Bool bIsMDIActivate)
 mpHorizontalRuler-SetActive(sal_False);
 if (mpVerticalRuler.get() != NULL)
 mpVerticalRuler-SetActive(sal_False);
-
-SfxShell::Deactivate(bIsMDIActivate);
+// Do not forward to SfxShell::Deactivate()
 }
 
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-07-10 Thread Michael Stahl
 sd/source/ui/slidesorter/controller/SlsListener.cxx |7 +++
 1 file changed, 7 insertions(+)

New commits:
commit d9b36d3623ce5d88bfaca7a31426fa126a6ce4ac
Author: Michael Stahl mst...@redhat.com
Date:   Wed Jul 10 15:43:42 2013 +0200

rhbz#965646: sd: unregister slide sorter listener to avoid crashes

sd::slidesorter::controller::Listener::Notify(): when the ~SdDrawDocument
sends a HINT_MODELCLEARED, unregister since the document doesn't exist
any more.  This should hopefully avoids accessing a SfxViewShell
instance that has apparently already been deleted somewhere in one of
the listeners.

Change-Id: I0ba9a58d77741a52b652a6c55c2327db80859011
(cherry picked from commit a9e0c222f504104124485ef4684ce6f79d3dee52)
Reviewed-on: https://gerrit.libreoffice.org/4813
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sd/source/ui/slidesorter/controller/SlsListener.cxx 
b/sd/source/ui/slidesorter/controller/SlsListener.cxx
index 17a8a14..e85a6c8 100644
--- a/sd/source/ui/slidesorter/controller/SlsListener.cxx
+++ b/sd/source/ui/slidesorter/controller/SlsListener.cxx
@@ -304,6 +304,13 @@ void Listener::Notify (
 SdrHint rSdrHint (*PTR_CAST(SdrHint,rHint));
 switch (rSdrHint.GetKind())
 {
+case HINT_MODELCLEARED:
+if (rBroadcaster == mrSlideSorter.GetModel().GetDocument())
+{   // rhbz#965646 stop listening to dying document
+EndListening(rBroadcaster);
+return;
+}
+break;
 case HINT_PAGEORDERCHG:
 if (rBroadcaster == mrSlideSorter.GetModel().GetDocument())
 HandleModelChange(rSdrHint.GetPage());
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-07-10 Thread Faisal M . Al-Otaibi
 sd/source/ui/view/drtxtob1.cxx |   16 +---
 1 file changed, 9 insertions(+), 7 deletions(-)

New commits:
commit b41378eae135982acdc910af3ff9987348f00fba
Author: Faisal M. Al-Otaibi fmalota...@kacst.edu.sa
Date:   Fri Jun 28 10:54:55 2013 +0200

fix crash when use increase font on table in impress

Change-Id: Id6c8cac4543d97657cb66b979f5dc4b5f903473a
Reviewed-on: https://gerrit.libreoffice.org/4797
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sd/source/ui/view/drtxtob1.cxx b/sd/source/ui/view/drtxtob1.cxx
index 572fbed..6ad4cf1 100644
--- a/sd/source/ui/view/drtxtob1.cxx
+++ b/sd/source/ui/view/drtxtob1.cxx
@@ -328,15 +328,17 @@ void TextObjectBar::Execute( SfxRequest rReq )
 if( pFontList )
 {
 FuText::ChangeFontSize( nSlot == SID_GROW_FONT_SIZE, pOLV, 
pFontList, mpView );
+if( pOLV )
+{
+SfxItemSet aSet( pOLV-GetEditView().GetAttribs() );
+SfxItemSet aNewAttrs 
(pOLV-GetEditView().GetEmptyItemSet() );
 
-SfxItemSet aSet( pOLV-GetEditView().GetAttribs() );
-SfxItemSet aNewAttrs (pOLV-GetEditView().GetEmptyItemSet() );
-
-aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT ), 
EE_CHAR_FONTHEIGHT );
-aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT_CJK ), 
EE_CHAR_FONTHEIGHT_CJK );
-aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT_CTL ), 
EE_CHAR_FONTHEIGHT_CTL );
+aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT ), 
EE_CHAR_FONTHEIGHT );
+aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT_CJK ), 
EE_CHAR_FONTHEIGHT_CJK );
+aNewAttrs.Put( aSet.Get( EE_CHAR_FONTHEIGHT_CTL ), 
EE_CHAR_FONTHEIGHT_CTL );
 
-mpView-SetAttributes( aNewAttrs );
+mpView-SetAttributes( aNewAttrs );
+}
 Invalidate();
 // to refresh preview (in outline mode), slot has to be 
invalidated:
 mpViewShell-GetViewFrame()-GetBindings().Invalidate( 
SID_PREVIEW_STATE, sal_True, sal_False );
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-06-26 Thread Thorsten Behrens
 sd/source/ui/dlg/tpoption.cxx |2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 78d3a693028195fdd2ebb5afbfb52fd823875109
Author: Thorsten Behrens tbehr...@suse.com
Date:   Wed Jun 26 19:44:01 2013 +0200

Fix fdo#65849 - really move control one line up.

If all other controls are moved up one line to fill the gap,
moving this one up one line relative to the rest needs a two-line
up-move.

Change-Id: I953f778dd0738dcd1d38fd2589f1ec9bc62ad611
Reviewed-on: https://gerrit.libreoffice.org/4548
Reviewed-by: Fridrich Strba fridr...@documentfoundation.org
Tested-by: Fridrich Strba fridr...@documentfoundation.org

diff --git a/sd/source/ui/dlg/tpoption.cxx b/sd/source/ui/dlg/tpoption.cxx
index 603cd60..57ad7bb 100644
--- a/sd/source/ui/dlg/tpoption.cxx
+++ b/sd/source/ui/dlg/tpoption.cxx
@@ -618,7 +618,7 @@ void SdTpOptionsMisc::SetImpressMode (void)
 lcl_MoveWin (aCbxEnableSdremote, -nLineHeight);
 lcl_MoveWin (aCbxEnablePresenterScreen,
 nDialogWidth/2 - aCbxEnablePresenterScreen.GetPosPixel().X(),
--nLineHeight);
+-2*nLineHeight);
 lcl_MoveWin (aTxtCompatibility, -nLineHeight);
 
 // Move the printer-independent-metrics check box up two lines to change
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-05-24 Thread Mark Wielaard
 sd/source/ui/view/drviewsf.cxx |3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 43a57daeb458fe202b42d4c36a72f9d51f2732df
Author: Mark Wielaard m...@klomp.org
Date:   Fri May 24 08:55:45 2013 +0200

Fix memory leak in DrawViewShell::GetAttrState().

DrawViewShell::GetAttrState() might create a temporary new SvxNumRule
object. Make sure it gets deleted when done.

Change-Id: I33ddd9df983193fe87dd076267043d202cdfc3d5
Reviewed-on: https://gerrit.libreoffice.org/4020
Reviewed-by: Caolán McNamara caol...@redhat.com
Tested-by: Caolán McNamara caol...@redhat.com
(cherry picked from commit a602bd1a69db5c6b4e0fa818324cdf4e0088778c)

diff --git a/sd/source/ui/view/drviewsf.cxx b/sd/source/ui/view/drviewsf.cxx
index 4989cd2..89c90d0 100644
--- a/sd/source/ui/view/drviewsf.cxx
+++ b/sd/source/ui/view/drviewsf.cxx
@@ -630,9 +630,10 @@ void DrawViewShell::GetAttrState( SfxItemSet rSet )
 }
 }
 }
+  delete pNumRule;
 }
 }
-break;
+break;
 //End
 // Added by Li Hui for story 179.
 case FN_NUM_BULLET_ON:
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits


[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source sfx2/source

2013-05-23 Thread Andre Fischer
 sd/source/ui/sidebar/NavigatorWrapper.cxx |9 +
 sd/source/ui/sidebar/NavigatorWrapper.hxx |1 
 sfx2/source/sidebar/FocusManager.cxx  |  150 ++
 sfx2/source/sidebar/FocusManager.hxx  |   18 +++
 4 files changed, 158 insertions(+), 20 deletions(-)

New commits:
commit ce7dafae81f226bd441723df49f68005919df91f
Author: Andre Fischer a...@apache.org
Date:   Thu May 23 14:30:17 2013 +

Resolves: #i122247# Improved focus traveling in sidebar

(cherry picked from commit 4b0aafb8182b1f86b9edf947a4c62ff9948c6676)

Change-Id: Ieae8e44fe147309cc3ff447a6dbc375d1b2f34d0
(cherry picked from commit ab0360c309adcd131a9e6c1f02abc82486d09a46)

diff --git a/sd/source/ui/sidebar/NavigatorWrapper.cxx 
b/sd/source/ui/sidebar/NavigatorWrapper.cxx
index ad870fc..0412362 100644
--- a/sd/source/ui/sidebar/NavigatorWrapper.cxx
+++ b/sd/source/ui/sidebar/NavigatorWrapper.cxx
@@ -81,4 +81,13 @@ void NavigatorWrapper::UpdateNavigator (void)
 }
 
 
+
+
+void NavigatorWrapper::GetFocus (void)
+{
+maNavigator.GrabFocus();
+}
+
+
+
 } } // end of namespace sd::sidebar
diff --git a/sd/source/ui/sidebar/NavigatorWrapper.hxx 
b/sd/source/ui/sidebar/NavigatorWrapper.hxx
index 669628d..26e6255 100644
--- a/sd/source/ui/sidebar/NavigatorWrapper.hxx
+++ b/sd/source/ui/sidebar/NavigatorWrapper.hxx
@@ -51,6 +51,7 @@ public:
 
 // Control
 virtual void Resize (void);
+virtual void GetFocus (void);
 
 // From ILayoutableWindow
 virtual css::ui::LayoutSize GetHeightForWidth (const sal_Int32 nWidth);
diff --git a/sfx2/source/sidebar/FocusManager.cxx 
b/sfx2/source/sidebar/FocusManager.cxx
index 51d4c5e..69c2e53 100644
--- a/sfx2/source/sidebar/FocusManager.cxx
+++ b/sfx2/source/sidebar/FocusManager.cxx
@@ -42,7 +42,9 @@ FocusManager::FocusManager (const 
::boost::functionvoid(const Panel) rShowPa
 : mpDeckTitleBar(),
   maPanels(),
   maButtons(),
-  maShowPanelFunctor(rShowPanelFunctor)
+  maShowPanelFunctor(rShowPanelFunctor),
+  mbObservingContentControlFocus(false),
+  mpFirstFocusedContentControl(NULL)
 {
 }
 
@@ -254,17 +256,23 @@ bool FocusManager::IsAnyButtonFocused (void) const
 
 void FocusManager::FocusDeckTitle (void)
 {
-if (IsDeckTitleVisible())
+if (mpDeckTitleBar != NULL)
 {
-ToolBox rToolBox = mpDeckTitleBar-GetToolBox();
-if (rToolBox.GetItemCount()  0)
+if (IsDeckTitleVisible())
+{
+mpDeckTitleBar-GrabFocus();
+}
+else if (mpDeckTitleBar-GetToolBox().GetItemCount()  0)
 {
+ToolBox rToolBox = mpDeckTitleBar-GetToolBox();
 rToolBox.GrabFocus();
 rToolBox.Invalidate();
 }
+else
+FocusPanel(0, false);
 }
 else
-FocusPanel(0);
+FocusPanel(0, false);
 }
 
 
@@ -278,10 +286,31 @@ bool FocusManager::IsDeckTitleVisible (void) const
 
 
 
-void FocusManager::FocusPanel (const sal_Int32 nPanelIndex)
+bool FocusManager::IsPanelTitleVisible (const sal_Int32 nPanelIndex) const
 {
 if (nPanelIndex0 || nPanelIndex=static_castsal_Int32(maPanels.size()))
+return false;
+
+TitleBar* pTitleBar = maPanels[nPanelIndex]-GetTitleBar();
+if (pTitleBar==NULL)
+return false;
+return pTitleBar-IsVisible();
+}
+
+
+
+
+void FocusManager::FocusPanel (
+const sal_Int32 nPanelIndex,
+const bool bFallbackToDeckTitle)
+{
+if (nPanelIndex0 || nPanelIndex=static_castsal_Int32(maPanels.size()))
+{
+if (bFallbackToDeckTitle)
+FocusDeckTitle();
 return;
+}
+
 Panel rPanel (*maPanels[nPanelIndex]);
 TitleBar* pTitleBar = rPanel.GetTitleBar();
 if (pTitleBar!=NULL  pTitleBar-IsVisible())
@@ -289,8 +318,21 @@ void FocusManager::FocusPanel (const sal_Int32 nPanelIndex)
 rPanel.SetExpanded(true);
 pTitleBar-GrabFocus();
 }
+else if (bFallbackToDeckTitle)
+{
+// The panel title is not visible, fall back to the deck
+// title.
+// Make sure that the desk title is visible here to prevent a
+// loop when both the title of panel 0 and the deck title are
+// not present.
+if (IsDeckTitleVisible())
+FocusDeckTitle();
+else
+FocusPanelContent(nPanelIndex);
+}
 else
 FocusPanelContent(nPanelIndex);
+
 if (maShowPanelFunctor)
 maShowPanelFunctor(rPanel);
 }
@@ -302,7 +344,11 @@ void FocusManager::FocusPanelContent (const sal_Int32 
nPanelIndex)
 {
 Window* pWindow = 
VCLUnoHelper::GetWindow(maPanels[nPanelIndex]-GetElementWindow());
 if (pWindow != NULL)
+{
+mbObservingContentControlFocus = true;
 pWindow-GrabFocus();
+mbObservingContentControlFocus = false;
+}
 }
 
 
@@ -322,7 +368,7 @@ void FocusManager::ClickButton (const sal_Int32 
nButtonIndex)
 maButtons[nButtonIndex]-Click();
 if (nButtonIndex  0)
 if ( ! 

[Libreoffice-commits] core.git: Branch 'libreoffice-4-1' - sd/source

2013-05-22 Thread Armin Le Grand
 sd/source/ui/slidesorter/model/SlideSorterModel.cxx |   35 
 1 file changed, 29 insertions(+), 6 deletions(-)

New commits:
commit 6cf3812ccc56c127fb13ac596ad762423f751316
Author: Armin Le Grand a...@apache.org
Date:   Mon Nov 12 16:29:06 2012 +

Secured SlideSorterModel::DeleteSlide for negative page indices

(cherry picked from commit f6bff98d6f13bf71fc4bce53c189598c002343c2)

Change-Id: I8c7ca633043ec224df4e4ab08c20d44f969a8059

Corrected signed/unsigned mix

(cherry picked from commit 20a3aee5359f143a6e4bf0bcb7fdef4675b3dd83)

Change-Id: I6f8ffc6f541c2a06c9e97ef06711f312adc438f2
(cherry picked from commit 5481d32d285178dbf1a974389da1ee7c8ae19939)

diff --git a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx 
b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
index 5b787d4..ca27a7a 100644
--- a/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
+++ b/sd/source/ui/slidesorter/model/SlideSorterModel.cxx
@@ -670,13 +670,36 @@ void SlideSorterModel::InsertSlide (SdPage* pPage)
 
 void SlideSorterModel::DeleteSlide (const SdPage* pPage)
 {
-const sal_Int32 nIndex (GetIndex(pPage));
-if (maPageDescriptors[nIndex])
-if (maPageDescriptors[nIndex]-GetPage() != pPage)
-return;
+sal_Int32 nIndex(0);
 
-maPageDescriptors.erase(maPageDescriptors.begin()+nIndex);
-UpdateIndices(nIndex);
+// Caution, GetIndex() may be negative since it uses GetPageNumber()-1
+// for calculation, so do this only when page is inserted, else the
+// GetPageNumber() will be zero and thus GetIndex() == -1
+if(pPage-IsInserted())
+{
+nIndex = GetIndex(pPage);
+}
+else
+{
+// if not inserted, search for page
+for(; nIndex  static_castsal_Int32(maPageDescriptors.size()); 
nIndex++)
+{
+if(maPageDescriptors[nIndex]-GetPage() == pPage)
+{
+break;
+}
+}
+}
+
+if(nIndex = 0  nIndex  
static_castsal_Int32(maPageDescriptors.size()))
+{
+if (maPageDescriptors[nIndex])
+if (maPageDescriptors[nIndex]-GetPage() != pPage)
+return;
+
+maPageDescriptors.erase(maPageDescriptors.begin()+nIndex);
+UpdateIndices(nIndex);
+}
 OSL_TRACE(page removed);
 }
 
___
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits