[Libreoffice-commits] core.git: 2 commits - sw/source sw/uiconfig

Caolán McNamara caolanm at redhat.com
Fri Aug 4 16:18:15 UTC 2017


 sw/source/core/doc/CntntIdxStore.cxx  |    2 +-
 sw/uiconfig/swriter/ui/insertbreak.ui |   24 ++++++++----------------
 2 files changed, 9 insertions(+), 17 deletions(-)

New commits:
commit f7c59aaa078576a413846b7c8024e728818ca2be
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 4 17:09:40 2017 +0100

    coverity#1416133 Unchecked dynamic_cast
    
    Change-Id: I6706e3f889c8c00bdc4bda56fe5f282472589a40

diff --git a/sw/source/core/doc/CntntIdxStore.cxx b/sw/source/core/doc/CntntIdxStore.cxx
index 1ba139572d2d..f164af01569f 100644
--- a/sw/source/core/doc/CntntIdxStore.cxx
+++ b/sw/source/core/doc/CntntIdxStore.cxx
@@ -269,7 +269,7 @@ void ContentIdxStoreImpl::RestoreBkmks(SwDoc* pDoc, updater_t const & rUpdater)
     if (!m_aBkmkEntries.empty())
     {   // tdf#105705 sort bookmarks because SaveBkmks special handling of
         // "bMarkPosEqual" may destroy sort order
-        dynamic_cast<sw::mark::MarkManager*>(pMarkAccess)->sortMarks();
+        dynamic_cast<sw::mark::MarkManager&>(*pMarkAccess).sortMarks();
     }
 }
 
commit 3b39ff8b4e71928e7f33452322522dea49aee1e4
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri Aug 4 16:34:14 2017 +0100

    tweak insert break menu to load the same with native gtk builder
    
    1) we can use a GtkComboBoxText for this simple case and move the liststore into the widget
    2) add the response ids for the buttons
    
    Change-Id: I7b3bd10c05f35b0e34bbbebc9f7a811f87d443ac

diff --git a/sw/uiconfig/swriter/ui/insertbreak.ui b/sw/uiconfig/swriter/ui/insertbreak.ui
index 0299a6bc66a3..12e2f94907b7 100644
--- a/sw/uiconfig/swriter/ui/insertbreak.ui
+++ b/sw/uiconfig/swriter/ui/insertbreak.ui
@@ -8,17 +8,6 @@
     <property name="step_increment">1</property>
     <property name="page_increment">10</property>
   </object>
-  <object class="GtkListStore" id="liststore1">
-    <columns>
-      <!-- column-name gchararray1 -->
-      <column type="gchararray"/>
-    </columns>
-    <data>
-      <row>
-        <col id="0" translatable="yes" context="insertbreak|liststore1">[None]</col>
-      </row>
-    </data>
-  </object>
   <object class="GtkDialog" id="BreakDialog">
     <property name="can_focus">False</property>
     <property name="border_width">6</property>
@@ -171,10 +160,13 @@
                       </packing>
                     </child>
                     <child>
-                      <object class="GtkComboBox" id="stylelb">
+                      <object class="GtkComboBoxText" id="stylelb">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
-                        <property name="model">liststore1</property>
+                        <property name="active">0</property>
+                        <items>
+                          <item translatable="yes" context="insertbreak|liststore1">[None]</item>
+                        </items>
                       </object>
                       <packing>
                         <property name="expand">False</property>
@@ -244,9 +236,9 @@
       </object>
     </child>
     <action-widgets>
-      <action-widget response="0">ok</action-widget>
-      <action-widget response="0">cancel</action-widget>
-      <action-widget response="0">help</action-widget>
+      <action-widget response="-5">ok</action-widget>
+      <action-widget response="-6">cancel</action-widget>
+      <action-widget response="-11">help</action-widget>
     </action-widgets>
   </object>
 </interface>


More information about the Libreoffice-commits mailing list