[Libreoffice-commits] core.git: 3 commits - dbaccess/source sd/source sd/uiconfig svx/source vcl/source

Caolán McNamara caolanm at redhat.com
Fri May 30 07:55:37 PDT 2014


 dbaccess/source/core/dataaccess/databasedocument.cxx |   78 +--
 dbaccess/source/core/dataaccess/databasedocument.hxx |   85 +++
 sd/source/filter/html/pubdlg.cxx                     |   30 +
 sd/uiconfig/simpress/ui/publishingdialog.ui          |  404 ++++++++-----------
 svx/source/dialog/dlgctl3d.cxx                       |    7 
 vcl/source/window/builder.cxx                        |    2 
 6 files changed, 326 insertions(+), 280 deletions(-)

New commits:
commit eaa89db886ba49472e22d77cea957a08c1113cd0
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri May 30 15:54:07 2014 +0100

    tweak massively complicated html export wizard a bit
    
    Change-Id: I1d15780d0128204f063a816df9df251b05ab93d2

diff --git a/sd/source/filter/html/pubdlg.cxx b/sd/source/filter/html/pubdlg.cxx
index 270845a..f1c758c 100644
--- a/sd/source/filter/html/pubdlg.cxx
+++ b/sd/source/filter/html/pubdlg.cxx
@@ -374,9 +374,31 @@ SdPublishingDlg::SdPublishingDlg(Window* pWindow, DocumentType eDocType)
 
     m_bImpress = eDocType == DOCUMENT_TYPE_IMPRESS;
 
+    Size aSize(LogicToPixel(Size(60, 50), MAP_APPFONT));
+    get(pPage2_Standard_FB, "standardFBImage");
+    pPage2_Standard_FB->set_width_request(aSize.Width());
+    pPage2_Standard_FB->set_height_request(aSize.Height());
+    get(pPage2_Frames_FB, "framesFBImage");
+    pPage2_Frames_FB->set_width_request(aSize.Width());
+    pPage2_Frames_FB->set_height_request(aSize.Height());
+    get(pPage2_Kiosk_FB, "kioskFBImage");
+    pPage2_Kiosk_FB->set_width_request(aSize.Width());
+    pPage2_Kiosk_FB->set_height_request(aSize.Height());
+    get(pPage2_WebCast_FB, "webCastFBImage");
+    pPage2_WebCast_FB->set_width_request(aSize.Width());
+    pPage2_WebCast_FB->set_height_request(aSize.Height());
+
+    get(pPage4_Misc, "miscTextview");
+    pPage4_Misc->set_height_request(pPage4_Misc->GetTextHeight() * 8);
+    pPage4_Misc->set_width_request(pPage4_Misc->approximate_char_width() * 52);
+
+    get(pPage1_Designs, "designsTreeview");
+    pPage1_Designs->set_height_request(pPage4_Misc->GetTextHeight() * 8);
+    pPage1_Designs->set_width_request(pPage4_Misc->approximate_char_width() * 52);
+
     //Lock down the preferred size based on the
     //initial max-size configuration
-    Size aSize(get_preferred_size());
+    aSize = get_preferred_size();
     set_width_request(aSize.Width());
     set_height_request(aSize.Height());
 
@@ -472,7 +494,6 @@ void SdPublishingDlg::CreatePages()
     get(pPage1_Titel, "assignLabel");
     get(pPage1_NewDesign, "newDesignRadiobutton");
     get(pPage1_OldDesign, "oldDesignRadiobutton");
-    get(pPage1_Designs, "designsTreeview");
     get(pPage1_DelDesign, "delDesingButton");
     get(pPage1_Desc, "descLabel");
     aAssistentFunc.InsertControl(1, pPage1);
@@ -494,10 +515,6 @@ void SdPublishingDlg::CreatePages()
     get(pPage2_SingleDocument, "singleDocumentRadiobutton");
     get(pPage2_Kiosk, "kioskRadiobutton");
     get(pPage2_WebCast, "webCastRadiobutton");
-    get(pPage2_Standard_FB, "standardFBImage");
-    get(pPage2_Frames_FB, "framesFBImage");
-    get(pPage2_Kiosk_FB, "kioskFBImage");
-    get(pPage2_WebCast_FB, "webCastFBImage");
     aAssistentFunc.InsertControl(2, pPage2);
     aAssistentFunc.InsertControl(2, pPage2Frame2);
     aAssistentFunc.InsertControl(2, pPage2Frame3);
@@ -592,7 +609,6 @@ void SdPublishingDlg::CreatePages()
     get(pPage4_WWW_txt, "wwwTxtLabel");
     get(pPage4_WWW, "wwwEntry");
     get(pPage4_Titel2, "addInformLabel");
-    get(pPage4_Misc, "miscTextview");
     get(pPage4_Download, "downloadCheckbutton");
     aAssistentFunc.InsertControl(4, pPage4);
     aAssistentFunc.InsertControl(4, pPage4_Titel1);
diff --git a/sd/uiconfig/simpress/ui/publishingdialog.ui b/sd/uiconfig/simpress/ui/publishingdialog.ui
index 0bfae2df..8d8c9b7 100644
--- a/sd/uiconfig/simpress/ui/publishingdialog.ui
+++ b/sd/uiconfig/simpress/ui/publishingdialog.ui
@@ -1,6 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
+<!-- Generated with glade 3.16.1 -->
 <interface>
-  <!-- interface-requires gtk+ 3.0 -->
+  <requires lib="gtk+" version="3.0"/>
   <!-- interface-requires LibreOffice 1.0 -->
   <object class="GtkDialog" id="PublishingDialog">
     <property name="can_focus">False</property>
@@ -43,7 +44,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
                         <property name="active">True</property>
@@ -63,7 +63,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="xalign">0</property>
                         <property name="draw_indicator">True</property>
                         <property name="group">newDesignRadiobutton</property>
@@ -113,7 +112,6 @@
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">True</property>
                                 <property name="valign">start</property>
-                                <property name="use_action_appearance">False</property>
                               </object>
                               <packing>
                                 <property name="expand">False</property>
@@ -136,6 +134,8 @@
                         <property name="can_focus">False</property>
                         <property name="halign">start</property>
                         <property name="label" translatable="yes">Select an existing design or create a new one</property>
+                        <property name="use_underline">True</property>
+                        <property name="mnemonic_widget">designsTreeview:border</property>
                       </object>
                       <packing>
                         <property name="expand">False</property>
@@ -202,7 +202,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
@@ -221,7 +220,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
                             <property name="group">ASPRadiobutton</property>
@@ -382,7 +380,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
@@ -401,7 +398,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
@@ -469,7 +465,6 @@
                                     <property name="visible">True</property>
                                     <property name="can_focus">True</property>
                                     <property name="receives_default">False</property>
-                                    <property name="use_action_appearance">False</property>
                                     <property name="use_underline">True</property>
                                     <property name="xalign">0</property>
                                     <property name="active">True</property>
@@ -543,7 +538,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="xalign">0</property>
                             <property name="active">True</property>
                             <property name="draw_indicator">True</property>
@@ -561,7 +555,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="xalign">0</property>
                             <property name="active">True</property>
                             <property name="draw_indicator">True</property>
@@ -611,49 +604,104 @@
                     <property name="top_padding">6</property>
                     <property name="left_padding">12</property>
                     <child>
-                      <object class="GtkBox" id="box5">
+                      <object class="GtkGrid" id="grid3">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
-                        <property name="hexpand">True</property>
-                        <property name="vexpand">True</property>
-                        <property name="orientation">vertical</property>
-                        <property name="spacing">6</property>
+                        <property name="row_spacing">6</property>
                         <child>
-                          <object class="GtkRadioButton" id="standardRadiobutton">
-                            <property name="label" translatable="yes">Standard H_TML format</property>
+                          <object class="GtkBox" id="box6">
+                            <property name="visible">True</property>
+                            <property name="can_focus">False</property>
+                            <property name="spacing">6</property>
+                            <child>
+                              <object class="GtkImage" id="standardFBImage">
+                                <property name="visible">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="pixbuf">sd/res/pubdes.png</property>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">1</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkImage" id="framesFBImage">
+                                <property name="can_focus">False</property>
+                                <property name="pixbuf">sd/res/pubdes2.png</property>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">2</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkImage" id="kioskFBImage">
+                                <property name="can_focus">False</property>
+                                <property name="pixbuf">sd/res/pubdes3.png</property>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">3</property>
+                              </packing>
+                            </child>
+                            <child>
+                              <object class="GtkImage" id="webCastFBImage">
+                                <property name="can_focus">False</property>
+                                <property name="pixbuf">sd/res/pubdes4.png</property>
+                              </object>
+                              <packing>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">4</property>
+                              </packing>
+                            </child>
+                          </object>
+                          <packing>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">5</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
+                          </packing>
+                        </child>
+                        <child>
+                          <object class="GtkRadioButton" id="webCastRadiobutton">
+                            <property name="label" translatable="yes">_WebCast</property>
                             <property name="use_action_appearance">False</property>
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
-                            <property name="group">framesRadiobutton</property>
+                            <property name="group">standardRadiobutton</property>
                           </object>
                           <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">0</property>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">4</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkRadioButton" id="framesRadiobutton">
-                            <property name="label" translatable="yes">Standard HTML with _frames</property>
+                          <object class="GtkRadioButton" id="kioskRadiobutton">
+                            <property name="label" translatable="yes">_Automatic</property>
                             <property name="use_action_appearance">False</property>
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
-                            <property name="group">standardRadiobutton</property>
+                            <property name="group">webCastRadiobutton</property>
                           </object>
                           <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">1</property>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">3</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
                           </packing>
                         </child>
                         <child>
@@ -663,111 +711,54 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
-                            <property name="group">standardRadiobutton</property>
+                            <property name="group">kioskRadiobutton</property>
                           </object>
                           <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">2</property>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">2</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkRadioButton" id="kioskRadiobutton">
-                            <property name="label" translatable="yes">_Automatic</property>
+                          <object class="GtkRadioButton" id="framesRadiobutton">
+                            <property name="label" translatable="yes">Standard HTML with _frames</property>
                             <property name="use_action_appearance">False</property>
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
-                            <property name="group">standardRadiobutton</property>
+                            <property name="group">singleDocumentRadiobutton</property>
                           </object>
                           <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">3</property>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">1</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
                           </packing>
                         </child>
                         <child>
-                          <object class="GtkRadioButton" id="webCastRadiobutton">
-                            <property name="label" translatable="yes">_WebCast</property>
+                          <object class="GtkRadioButton" id="standardRadiobutton">
+                            <property name="label" translatable="yes">Standard H_TML format</property>
                             <property name="use_action_appearance">False</property>
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
-                            <property name="group">standardRadiobutton</property>
-                          </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">4</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <object class="GtkBox" id="box6">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="spacing">6</property>
-                            <child>
-                              <object class="GtkImage" id="standardFBImage">
-                                <property name="visible">True</property>
-                                <property name="can_focus">False</property>
-                                <property name="pixbuf">sd/res/pubdes.png</property>
-                              </object>
-                              <packing>
-                                <property name="expand">False</property>
-                                <property name="fill">True</property>
-                                <property name="position">1</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkImage" id="framesFBImage">
-                                <property name="can_focus">False</property>
-                                <property name="pixbuf">sd/res/pubdes2.png</property>
-                              </object>
-                              <packing>
-                                <property name="expand">False</property>
-                                <property name="fill">True</property>
-                                <property name="position">2</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkImage" id="kioskFBImage">
-                                <property name="can_focus">False</property>
-                                <property name="pixbuf">sd/res/pubdes3.png</property>
-                              </object>
-                              <packing>
-                                <property name="expand">False</property>
-                                <property name="fill">True</property>
-                                <property name="position">3</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkImage" id="webCastFBImage">
-                                <property name="can_focus">False</property>
-                                <property name="pixbuf">sd/res/pubdes4.png</property>
-                              </object>
-                              <packing>
-                                <property name="expand">False</property>
-                                <property name="fill">True</property>
-                                <property name="position">4</property>
-                              </packing>
-                            </child>
+                            <property name="group">framesRadiobutton</property>
                           </object>
                           <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">5</property>
+                            <property name="left_attach">0</property>
+                            <property name="top_attach">0</property>
+                            <property name="width">1</property>
+                            <property name="height">1</property>
                           </packing>
                         </child>
                       </object>
@@ -811,7 +802,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">False</property>
                 <property name="hexpand">True</property>
-                <property name="vexpand">True</property>
                 <property name="spacing">24</property>
                 <property name="homogeneous">True</property>
                 <child>
@@ -819,7 +809,6 @@
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
                     <property name="hexpand">True</property>
-                    <property name="vexpand">True</property>
                     <property name="label_xalign">0</property>
                     <property name="shadow_type">none</property>
                     <child>
@@ -827,7 +816,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
                         <property name="hexpand">True</property>
-                        <property name="vexpand">True</property>
                         <property name="top_padding">6</property>
                         <property name="bottom_padding">6</property>
                         <property name="left_padding">12</property>
@@ -837,7 +825,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="hexpand">True</property>
-                            <property name="vexpand">True</property>
                             <property name="orientation">vertical</property>
                             <property name="spacing">6</property>
                             <child>
@@ -847,7 +834,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
                                 <property name="active">True</property>
@@ -867,7 +853,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
                                 <property name="draw_indicator">True</property>
@@ -886,7 +871,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
                                 <property name="draw_indicator">True</property>
@@ -911,6 +895,7 @@
                                     <property name="halign">start</property>
                                     <property name="label" translatable="yes">_Quality</property>
                                     <property name="use_underline">True</property>
+                                    <property name="mnemonic_widget">qualityCombobox</property>
                                   </object>
                                   <packing>
                                     <property name="expand">False</property>
@@ -967,12 +952,14 @@
                   <object class="GtkFrame" id="frame7">
                     <property name="visible">True</property>
                     <property name="can_focus">False</property>
+                    <property name="hexpand">True</property>
                     <property name="label_xalign">0</property>
                     <property name="shadow_type">none</property>
                     <child>
                       <object class="GtkAlignment" id="alignment10">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
+                        <property name="hexpand">True</property>
                         <property name="top_padding">6</property>
                         <property name="left_padding">12</property>
                         <child>
@@ -988,7 +975,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
                                 <property name="active">True</property>
@@ -1008,7 +994,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
                                 <property name="draw_indicator">True</property>
@@ -1027,7 +1012,6 @@
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">False</property>
-                                <property name="use_action_appearance">False</property>
                                 <property name="relief">half</property>
                                 <property name="use_underline">True</property>
                                 <property name="xalign">0</property>
@@ -1093,7 +1077,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="active">True</property>
@@ -1112,7 +1095,6 @@
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">False</property>
-                            <property name="use_action_appearance">False</property>
                             <property name="use_underline">True</property>
                             <property name="xalign">0</property>
                             <property name="draw_indicator">True</property>
@@ -1299,7 +1281,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
                         <property name="draw_indicator">True</property>
@@ -1362,7 +1343,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="relief">half</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
@@ -1376,7 +1356,7 @@
                       </packing>
                     </child>
                     <child>
-                      <object class="svtlo-ValueSet" id="buttonsDrawingarea">
+                      <object class="svtlo-ValueSet" id="buttonsDrawingarea:border">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
                         <property name="hexpand">True</property>
@@ -1440,7 +1420,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
                         <property name="active">True</property>
@@ -1460,7 +1439,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
                         <property name="draw_indicator">True</property>
@@ -1479,7 +1457,6 @@
                         <property name="visible">True</property>
                         <property name="can_focus">True</property>
                         <property name="receives_default">False</property>
-                        <property name="use_action_appearance">False</property>
                         <property name="use_underline">True</property>
                         <property name="xalign">0</property>
                         <property name="draw_indicator">True</property>
@@ -1492,120 +1469,122 @@
                       </packing>
                     </child>
                     <child>
-                      <object class="GtkBox" id="box24">
+                      <object class="GtkAlignment" id="alignment16">
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
-                        <property name="hexpand">True</property>
-                        <property name="vexpand">True</property>
-                        <property name="spacing">12</property>
+                        <property name="left_padding">12</property>
                         <child>
-                          <object class="GtkGrid" id="grid2">
+                          <object class="GtkBox" id="box24">
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
-                            <property name="row_spacing">6</property>
+                            <property name="hexpand">True</property>
+                            <property name="vexpand">True</property>
+                            <property name="spacing">12</property>
                             <child>
-                              <object class="GtkButton" id="vLinkButton">
-                                <property name="label" translatable="yes">_Visited Link</property>
-                                <property name="use_action_appearance">False</property>
+                              <object class="GtkGrid" id="grid2">
                                 <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="receives_default">True</property>
-                                <property name="use_action_appearance">False</property>
-                                <property name="use_underline">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="row_spacing">6</property>
+                                <child>
+                                  <object class="GtkButton" id="vLinkButton">
+                                    <property name="label" translatable="yes">_Visited Link</property>
+                                    <property name="use_action_appearance">False</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">True</property>
+                                    <property name="use_underline">True</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">0</property>
+                                    <property name="top_attach">3</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <object class="GtkButton" id="aLinkButton">
+                                    <property name="label" translatable="yes">Active Li_nk</property>
+                                    <property name="use_action_appearance">False</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">True</property>
+                                    <property name="use_underline">True</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">0</property>
+                                    <property name="top_attach">2</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <object class="GtkButton" id="linkButton">
+                                    <property name="label" translatable="yes">Hyper_link</property>
+                                    <property name="use_action_appearance">False</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">True</property>
+                                    <property name="use_underline">True</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">0</property>
+                                    <property name="top_attach">1</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
+                                <child>
+                                  <object class="GtkButton" id="textButton">
+                                    <property name="label" translatable="yes">Text</property>
+                                    <property name="use_action_appearance">False</property>
+                                    <property name="visible">True</property>
+                                    <property name="can_focus">True</property>
+                                    <property name="receives_default">True</property>
+                                  </object>
+                                  <packing>
+                                    <property name="left_attach">0</property>
+                                    <property name="top_attach">0</property>
+                                    <property name="width">1</property>
+                                    <property name="height">1</property>
+                                  </packing>
+                                </child>
                               </object>
                               <packing>
-                                <property name="left_attach">0</property>
-                                <property name="top_attach">3</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">0</property>
                               </packing>
                             </child>
                             <child>
-                              <object class="GtkButton" id="aLinkButton">
-                                <property name="label" translatable="yes">Active Li_nk</property>
-                                <property name="use_action_appearance">False</property>
+                              <object class="sduilo-SdHtmlAttrPreview" id="previewDrawingarea:border">
                                 <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="receives_default">True</property>
-                                <property name="use_action_appearance">False</property>
-                                <property name="use_underline">True</property>
+                                <property name="can_focus">False</property>
+                                <property name="hexpand">True</property>
+                                <property name="vexpand">True</property>
                               </object>
                               <packing>
-                                <property name="left_attach">0</property>
-                                <property name="top_attach">2</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">1</property>
                               </packing>
                             </child>
                             <child>
-                              <object class="GtkButton" id="linkButton">
-                                <property name="label" translatable="yes">Hyper_link</property>
+                              <object class="GtkButton" id="backButton">
+                                <property name="label" translatable="yes">Bac_kground</property>
                                 <property name="use_action_appearance">False</property>
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
                                 <property name="receives_default">True</property>
-                                <property name="use_action_appearance">False</property>
+                                <property name="valign">start</property>
                                 <property name="use_underline">True</property>
                               </object>
                               <packing>
-                                <property name="left_attach">0</property>
-                                <property name="top_attach">1</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkButton" id="textButton">
-                                <property name="label" translatable="yes">Text</property>
-                                <property name="use_action_appearance">False</property>
-                                <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="receives_default">True</property>
-                                <property name="use_action_appearance">False</property>
-                              </object>
-                              <packing>
-                                <property name="left_attach">0</property>
-                                <property name="top_attach">0</property>
-                                <property name="width">1</property>
-                                <property name="height">1</property>
+                                <property name="expand">False</property>
+                                <property name="fill">True</property>
+                                <property name="position">2</property>
                               </packing>
                             </child>
                           </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">0</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <object class="sduilo-SdHtmlAttrPreview" id="previewDrawingarea">
-                            <property name="visible">True</property>
-                            <property name="can_focus">False</property>
-                            <property name="hexpand">True</property>
-                            <property name="vexpand">True</property>
-                          </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">1</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <object class="GtkButton" id="backButton">
-                            <property name="label" translatable="yes">Bac_kground</property>
-                            <property name="use_action_appearance">False</property>
-                            <property name="visible">True</property>
-                            <property name="can_focus">True</property>
-                            <property name="receives_default">True</property>
-                            <property name="valign">start</property>
-                            <property name="use_action_appearance">False</property>
-                            <property name="use_underline">True</property>
-                          </object>
-                          <packing>
-                            <property name="expand">False</property>
-                            <property name="fill">True</property>
-                            <property name="position">2</property>
-                          </packing>
                         </child>
                       </object>
                       <packing>
@@ -1645,7 +1624,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</property>
                 <property name="use_stock">True</property>
               </object>
               <packing>
@@ -1661,7 +1639,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</property>
                 <property name="use_stock">True</property>
               </object>
               <packing>
@@ -1677,7 +1654,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</property>
               </object>
               <packing>
                 <property name="expand">False</property>
@@ -1694,7 +1670,6 @@
                 <property name="can_default">True</property>
                 <property name="has_default">True</property>
                 <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</property>
                 <property name="use_underline">True</property>
               </object>
               <packing>
@@ -1710,7 +1685,6 @@
                 <property name="visible">True</property>
                 <property name="can_focus">True</property>
                 <property name="receives_default">True</property>
-                <property name="use_action_appearance">False</property>
                 <property name="use_underline">True</property>
               </object>
               <packing>
diff --git a/vcl/source/window/builder.cxx b/vcl/source/window/builder.cxx
index fb0356a..97271e8 100644
--- a/vcl/source/window/builder.cxx
+++ b/vcl/source/window/builder.cxx
@@ -1429,7 +1429,7 @@ Window *VclBuilder::makeObject(Window *pParent, const OString &name, const OStri
     else if (name == "GtkImage")
     {
         extractStock(id, rMap);
-        pWindow = new FixedImage(pParent, WB_CENTER|WB_VCENTER|WB_3DLOOK);
+        pWindow = new FixedImage(pParent, WB_CENTER|WB_VCENTER|WB_3DLOOK|WB_SCALE);
         //such parentless GtkImages are temps used to set icons on buttons
         //default them to hidden to stop e.g. insert->index entry flicking temp
         //full screen windows
commit 48a697ef1c123812c47e7e7c33688ca2b2c5e93a
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri May 30 15:35:46 2014 +0100

    coverity#706394 Uncaught exception
    
    and hopefully a bunch more of those in dbaccess
    
    Change-Id: I5aefcfe56a697f9e6b18dfe167fdd8a4f54ab6e0

diff --git a/dbaccess/source/core/dataaccess/databasedocument.cxx b/dbaccess/source/core/dataaccess/databasedocument.cxx
index 7ff3492..86a4f15 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.cxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.cxx
@@ -628,7 +628,7 @@ namespace
 
 sal_Bool SAL_CALL ODatabaseDocument::wasModifiedSinceLastSave() throw ( RuntimeException, std::exception )
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     // The implementation here is somewhat sloppy, in that it returns whether *any* part of the whole
     // database document, including opened sub components, is modified. This is more than what is requested:
@@ -666,7 +666,7 @@ sal_Bool SAL_CALL ODatabaseDocument::wasModifiedSinceLastSave() throw ( RuntimeE
 
 void SAL_CALL ODatabaseDocument::storeToRecoveryFile( const OUString& i_TargetLocation, const Sequence< PropertyValue >& i_MediaDescriptor ) throw ( RuntimeException, IOException, WrappedTargetException, std::exception )
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     ModifyLock aLock( *this );
 
     try
@@ -810,7 +810,7 @@ Sequence< PropertyValue > SAL_CALL ODatabaseDocument::getArgs(  ) throw (Runtime
 
 void SAL_CALL ODatabaseDocument::connectController( const Reference< XController >& _xController ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
 #if OSL_DEBUG_LEVEL > 0
     for (   Controllers::const_iterator controller = m_aControllers.begin();
@@ -842,7 +842,7 @@ void SAL_CALL ODatabaseDocument::disconnectController( const Reference< XControl
 
     // SYNCHRONIZED ->
     {
-        DocumentGuard aGuard( *this );
+        DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
         Controllers::iterator pos = ::std::find( m_aControllers.begin(), m_aControllers.end(), _xController );
         OSL_ENSURE( pos != m_aControllers.end(), "ODatabaseDocument::disconnectController: don't know this controller!" );
@@ -880,35 +880,35 @@ void SAL_CALL ODatabaseDocument::disconnectController( const Reference< XControl
 
 void SAL_CALL ODatabaseDocument::lockControllers(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     ++m_pImpl->m_nControllerLockCount;
 }
 
 void SAL_CALL ODatabaseDocument::unlockControllers(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     --m_pImpl->m_nControllerLockCount;
 }
 
 sal_Bool SAL_CALL ODatabaseDocument::hasControllersLocked(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     return m_pImpl->m_nControllerLockCount != 0;
 }
 
 Reference< XController > SAL_CALL ODatabaseDocument::getCurrentController() throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     return m_xCurrentController.is() ? m_xCurrentController : ( m_aControllers.empty() ? Reference< XController >() : *m_aControllers.begin() );
 }
 
 void SAL_CALL ODatabaseDocument::setCurrentController( const Reference< XController >& _xController ) throw (NoSuchElementException, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     m_xCurrentController = _xController;
 
@@ -937,7 +937,7 @@ void SAL_CALL ODatabaseDocument::setCurrentController( const Reference< XControl
 
 Reference< XInterface > SAL_CALL ODatabaseDocument::getCurrentSelection(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     Reference< XInterface > xRet;
     Reference< XSelectionSupplier >  xDocView( getCurrentController(), UNO_QUERY );
@@ -969,7 +969,7 @@ sal_Bool SAL_CALL ODatabaseDocument::isReadonly(  ) throw (RuntimeException, std
 
 void SAL_CALL ODatabaseDocument::store(  ) throw (IOException, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     OUString sDocumentURL( m_pImpl->getURL() );
     if ( !sDocumentURL.isEmpty() )
@@ -1224,7 +1224,7 @@ void ODatabaseDocument::impl_storeToStorage_throw( const Reference< XStorage >&
 
 void SAL_CALL ODatabaseDocument::storeToURL( const OUString& _rURL, const Sequence< PropertyValue >& _rArguments ) throw (IOException, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     ModifyLock aLock( *this );
 
     {
@@ -1266,20 +1266,20 @@ void SAL_CALL ODatabaseDocument::storeToURL( const OUString& _rURL, const Sequen
 // XModifyBroadcaster
 void SAL_CALL ODatabaseDocument::addModifyListener( const Reference< XModifyListener >& _xListener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aModifyListeners.addInterface(_xListener);
 }
 
 void SAL_CALL ODatabaseDocument::removeModifyListener( const Reference< XModifyListener >& _xListener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aModifyListeners.removeInterface(_xListener);
 }
 
 // XModifiable
 sal_Bool SAL_CALL ODatabaseDocument::isModified(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     return m_pImpl->m_bModified;
 }
@@ -1341,7 +1341,7 @@ void SAL_CALL ODatabaseDocument::notifyDocumentEvent( const OUString& _EventName
         throw IllegalArgumentException( OUString(), *this, 1 );
 
     // SYNCHRONIZED ->
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     if ( !DocumentEvents::needsSynchronousNotification( _EventName ) )
     {
@@ -1481,7 +1481,7 @@ void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (Clo
     // the checks for being disposed and the like
     // SYNCHRONIZED ->
     {
-        DocumentGuard aGuard( *this );
+        DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
         m_bClosing = true;
     }
     // <- SYNCHRONIZED
@@ -1517,13 +1517,13 @@ void SAL_CALL ODatabaseDocument::close( sal_Bool _bDeliverOwnership ) throw (Clo
 
 void SAL_CALL ODatabaseDocument::addCloseListener( const Reference< ::com::sun::star::util::XCloseListener >& Listener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aCloseListener.addInterface(Listener);
 }
 
 void SAL_CALL ODatabaseDocument::removeCloseListener( const Reference< ::com::sun::star::util::XCloseListener >& Listener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aCloseListener.removeInterface(Listener);
 }
 
@@ -1682,7 +1682,7 @@ Reference< XUIConfigurationManager > SAL_CALL ODatabaseDocument::getUIConfigurat
 
 Reference< XUIConfigurationManager2 > ODatabaseDocument::getUIConfigurationManager2(  ) throw (RuntimeException)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     if ( !m_xUIConfigurationManager.is() )
     {
@@ -1717,7 +1717,7 @@ Reference< XUIConfigurationManager2 > ODatabaseDocument::getUIConfigurationManag
 
 Reference< XStorage > SAL_CALL ODatabaseDocument::getDocumentSubStorage( const OUString& aStorageName, sal_Int32 nMode ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     Reference< XDocumentSubStorageSupplier > xStorageAccess( m_pImpl->getDocumentSubStorageSupplier() );
     return xStorageAccess->getDocumentSubStorage( aStorageName, nMode );
@@ -1881,7 +1881,7 @@ Reference< XDataSource > SAL_CALL ODatabaseDocument::getDataSource() throw (Runt
 
 void SAL_CALL ODatabaseDocument::loadFromStorage( const Reference< XStorage >& /*xStorage*/, const Sequence< PropertyValue >& /*aMediaDescriptor*/ ) throw (IllegalArgumentException, DoubleInitializationException, IOException, Exception, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     throw Exception(
         DBACORE_RESSTRING( RID_STR_NO_EMBEDDING ),
@@ -1891,13 +1891,13 @@ void SAL_CALL ODatabaseDocument::loadFromStorage( const Reference< XStorage >& /
 
 void SAL_CALL ODatabaseDocument::storeToStorage( const Reference< XStorage >& _rxStorage, const Sequence< PropertyValue >& _rMediaDescriptor ) throw (IllegalArgumentException, IOException, Exception, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     impl_storeToStorage_throw( _rxStorage, _rMediaDescriptor, aGuard );
 }
 
 void SAL_CALL ODatabaseDocument::switchToStorage( const Reference< XStorage >& _rxNewRootStorage ) throw (IllegalArgumentException, IOException, Exception, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     Reference< XStorage > xNewRootStorage( m_pImpl->switchToStorage( _rxNewRootStorage ) );
 
@@ -1907,19 +1907,19 @@ void SAL_CALL ODatabaseDocument::switchToStorage( const Reference< XStorage >& _
 
 Reference< XStorage > SAL_CALL ODatabaseDocument::getDocumentStorage(  ) throw (IOException, Exception, RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     return m_pImpl->getOrCreateRootStorage();
 }
 
 void SAL_CALL ODatabaseDocument::addStorageChangeListener( const Reference< XStorageChangeListener >& _Listener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aStorageListeners.addInterface( _Listener );
 }
 
 void SAL_CALL ODatabaseDocument::removeStorageChangeListener( const Reference< XStorageChangeListener >& _Listener ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     m_aStorageListeners.addInterface( _Listener );
 }
 
@@ -1931,25 +1931,25 @@ Reference< XStorageBasedLibraryContainer > SAL_CALL ODatabaseDocument::getBasicL
 
 Reference< XStorageBasedLibraryContainer > SAL_CALL ODatabaseDocument::getDialogLibraries() throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     return m_pImpl->getLibraryContainer( false );
 }
 
 sal_Bool SAL_CALL ODatabaseDocument::getAllowMacroExecution() throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     return m_pImpl->adjustMacroMode_AutoReject();
 }
 
 Reference< XEmbeddedScripts > SAL_CALL ODatabaseDocument::getScriptContainer() throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     return this;
 }
 
 Reference< provider::XScriptProvider > SAL_CALL ODatabaseDocument::getScriptProvider(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     Reference< XScriptProvider > xScriptProvider( m_xScriptProvider );
     if ( !xScriptProvider.is() )
@@ -1996,7 +1996,7 @@ struct CreateAny : public ::std::unary_function< Reference<XController>, Any>
 // XModel2
 Reference< XEnumeration > SAL_CALL ODatabaseDocument::getControllers(  ) throw (RuntimeException, std::exception)
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     uno::Sequence< Any> aController( m_aControllers.size() );
     ::std::transform( m_aControllers.begin(), m_aControllers.end(), aController.getArray(), CreateAny() );
     return new ::comphelper::OAnyEnumeration(aController);
@@ -2021,7 +2021,7 @@ Reference< XController2 > SAL_CALL ODatabaseDocument::createViewController( cons
     if ( !_Frame.is() )
         throw IllegalArgumentException( OUString(), *this, 3 );
 
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     aGuard.clear();
 
     Reference< XController2 > xController(
@@ -2100,7 +2100,7 @@ void SAL_CALL ODatabaseDocument::setTitle( const OUString& sTitle )
     throw (uno::RuntimeException, std::exception)
 {
     // SYNCHRONIZED ->
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     impl_getTitleHelper_throw()->setTitle( sTitle );
     m_aEventNotifier.notifyDocumentEventAsync( "OnTitleChanged" );
     // <- SYNCHRONIZED
@@ -2111,7 +2111,7 @@ void SAL_CALL ODatabaseDocument::addTitleChangeListener( const uno::Reference< f
     throw (uno::RuntimeException, std::exception)
 {
     // SYNCHRONIZED ->
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     uno::Reference< frame::XTitleChangeBroadcaster > xBroadcaster( impl_getTitleHelper_throw(), uno::UNO_QUERY_THROW );
     xBroadcaster->addTitleChangeListener( xListener );
@@ -2122,7 +2122,7 @@ void SAL_CALL ODatabaseDocument::removeTitleChangeListener( const uno::Reference
     throw (uno::RuntimeException, std::exception)
 {
     // SYNCHRONIZED ->
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
 
     uno::Reference< frame::XTitleChangeBroadcaster > xBroadcaster( impl_getTitleHelper_throw(), uno::UNO_QUERY_THROW );
     xBroadcaster->removeTitleChangeListener( xListener );
@@ -2133,7 +2133,7 @@ void SAL_CALL ODatabaseDocument::removeTitleChangeListener( const uno::Reference
     throw (lang::IllegalArgumentException,
            uno::RuntimeException, std::exception         )
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     return impl_getUntitledHelper_throw(xComponent)->leaseNumber (xComponent);
 }
 
@@ -2142,7 +2142,7 @@ void SAL_CALL ODatabaseDocument::releaseNumber( ::sal_Int32 nNumber )
     throw (lang::IllegalArgumentException,
            uno::RuntimeException, std::exception         )
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     impl_getUntitledHelper_throw()->releaseNumber (nNumber);
 }
 
@@ -2151,7 +2151,7 @@ void SAL_CALL ODatabaseDocument::releaseNumberForComponent( const uno::Reference
     throw (lang::IllegalArgumentException,
            uno::RuntimeException, std::exception         )
 {
-    DocumentGuard aGuard( *this );
+    DocumentGuard aGuard(*this, DocumentGuard::DefaultMethod);
     impl_getUntitledHelper_throw(xComponent)->releaseNumberForComponent (xComponent);
 }
 
diff --git a/dbaccess/source/core/dataaccess/databasedocument.hxx b/dbaccess/source/core/dataaccess/databasedocument.hxx
index 73096e5..bd5f946 100644
--- a/dbaccess/source/core/dataaccess/databasedocument.hxx
+++ b/dbaccess/source/core/dataaccess/databasedocument.hxx
@@ -631,18 +631,49 @@ private:
 class DocumentGuard : private ModelMethodGuard
 {
 public:
-    enum MethodType
+    enum __InitMethod
     {
         // a method which is to initialize the document
         InitMethod,
+    };
+
+    enum __DefaultMethod
+    {
         // a default method
-        DefaultMethod,
+        DefaultMethod
+    };
+
+    enum __MethodUsedDuringInit
+    {
         // a method which is used (externally) during the initialization phase
-        MethodUsedDuringInit,
+        MethodUsedDuringInit
+    };
+
+    enum __MethodWithoutInit
+    {
         // a method which does not need initialization - use with care!
         MethodWithoutInit
     };
 
+
+    /** constructs the guard
+
+        @param _document
+            the ODatabaseDocument instance
+
+        @throws ::com::sun::star::lang::DisposedException
+            If the given component is already disposed
+
+        @throws ::com::sun::star::lang::NotInitializedException
+            if the given component is not yet initialized
+    */
+    DocumentGuard(const ODatabaseDocument& _document, __DefaultMethod)
+        : ModelMethodGuard(_document)
+        , m_document(_document )
+    {
+        m_document.checkInitialized();
+    }
+
     /** constructs the guard
 
         @param _document
@@ -652,24 +683,46 @@ public:
             If the given component is already disposed
 
         @throws ::com::sun::star::frame::DoubleInitializationException
-            if _eType is InitMethod, and the given component is already initialized, or currently being initialized.
+            if the given component is already initialized, or currently being initialized.
+    */
+    DocumentGuard(const ODatabaseDocument& _document, __InitMethod)
+        : ModelMethodGuard(_document)
+        , m_document(_document)
+    {
+        m_document.checkNotInitialized();
+    }
+
+    /** constructs the guard
+
+        @param _document
+            the ODatabaseDocument instance
+
+        @throws ::com::sun::star::lang::DisposedException
+            If the given component is already disposed
 
         @throws ::com::sun::star::lang::NotInitializedException
-            if _eType is DefaultMethod, and the given component is not yet initialized; or if _eType
-            is MethodUsedDuringInit, and the component is still uninitialized, and not in the initialization
+            if the component is still uninitialized, and not in the initialization
             phase currently.
     */
-    DocumentGuard( const ODatabaseDocument& _document, MethodType _eType = DefaultMethod )
-        :ModelMethodGuard( _document )
-        ,m_document( _document )
+    DocumentGuard(const ODatabaseDocument& _document, __MethodUsedDuringInit)
+        : ModelMethodGuard(_document)
+        , m_document(_document)
+    {
+        m_document.checkNotUninitilized();
+    }
+
+    /** constructs the guard
+
+        @param _document
+            the ODatabaseDocument instance
+
+        @throws ::com::sun::star::lang::DisposedException
+            If the given component is already disposed
+    */
+    DocumentGuard(const ODatabaseDocument& _document, __MethodWithoutInit)
+        : ModelMethodGuard( _document )
+        , m_document( _document )
     {
-        switch ( _eType )
-        {
-            case InitMethod:            m_document.checkNotInitialized();    break;
-            case DefaultMethod:         m_document.checkInitialized();       break;
-            case MethodUsedDuringInit:  m_document.checkNotUninitilized();   break;
-            case MethodWithoutInit:                                         break;
-        }
     }
 
     ~DocumentGuard()
commit 535780bd4b911cb86b3587cead72ea15d23df871
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Fri May 30 14:52:48 2014 +0100

    coverity#704809 Explicit null dereferenced
    
    Change-Id: I8febb74648b409e214e805084682d932424252b3

diff --git a/svx/source/dialog/dlgctl3d.cxx b/svx/source/dialog/dlgctl3d.cxx
index a1e20bf..f912768 100644
--- a/svx/source/dialog/dlgctl3d.cxx
+++ b/svx/source/dialog/dlgctl3d.cxx
@@ -224,8 +224,11 @@ void Svx3DPreviewControl::SetObjectType(sal_uInt16 nType)
             break;
         }
 
-        mpScene->Insert3DObj( mp3DObj );
-        mp3DObj->SetMergedItemSet(aSet);
+        if (mp3DObj)
+        {
+            mpScene->Insert3DObj( mp3DObj );
+            mp3DObj->SetMergedItemSet(aSet);
+        }
 
         Resize();
     }


More information about the Libreoffice-commits mailing list