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

Zolnai Tamás tamas.zolnai at collabora.com
Fri Jan 10 05:13:05 PST 2014


 include/sfx2/recentdocsviewitem.hxx        |    3 +++
 sfx2/source/control/recentdocsviewitem.cxx |    6 +++---
 sfx2/source/dialog/backingwindow.cxx       |    3 ---
 sfx2/uiconfig/ui/startcenter.ui            |    3 ++-
 4 files changed, 8 insertions(+), 7 deletions(-)

New commits:
commit 60c7ed80643a6c397feebdd1492d6c3ef4d810be
Author: Zolnai Tamás <tamas.zolnai at collabora.com>
Date:   Fri Jan 10 03:31:46 2014 +0100

    fdo#72947 Startcenter: display more userfriendly file urls in tooltips
    
    Use INetURLObject to get a readable url (it displayes special characters
    too). It is a side effect that 'file:///' prefix disappear
    which seems a good thing.
    Plus some cleanup: remove second INetURLObject.
    
    Change-Id: I4aab5e2546ae70e5a3d85b12e26e021bfa244999

diff --git a/include/sfx2/recentdocsviewitem.hxx b/include/sfx2/recentdocsviewitem.hxx
index be94b78..410e74b 100644
--- a/include/sfx2/recentdocsviewitem.hxx
+++ b/include/sfx2/recentdocsviewitem.hxx
@@ -23,6 +23,9 @@ public:
     virtual OUString getHelpText() const;
 
     OUString maURL;
+
+private:
+    OUString m_sHelpText;
 };
 
 #endif // INCLUDED_SFX2_RECENTDOCSVIEWITEM_HXX
diff --git a/sfx2/source/control/recentdocsviewitem.cxx b/sfx2/source/control/recentdocsviewitem.cxx
index c35c16b..d741675 100644
--- a/sfx2/source/control/recentdocsviewitem.cxx
+++ b/sfx2/source/control/recentdocsviewitem.cxx
@@ -21,6 +21,7 @@ RecentDocsViewItem::RecentDocsViewItem(ThumbnailView &rView, const OUString &rUR
 {
     OUString aTitle(rTitle);
     INetURLObject aURLObj(rURL);
+    m_sHelpText = aURLObj.GetURLPath();
     RecentDocsView& rRecentView = dynamic_cast<RecentDocsView&>(rView);
     long nThumbnailSize = rRecentView.GetThumbnailSize();
 
@@ -38,10 +39,9 @@ RecentDocsViewItem::RecentDocsViewItem(ThumbnailView &rView, const OUString &rUR
         Size aExtSize(aExt.GetSizePixel());
 
         // attempt to make it appear as if it is on a piece of paper
-        INetURLObject aUrl(rURL);
         long nPaperHeight;
         long nPaperWidth;
-        if( RecentDocsView::typeMatchesExtension(TYPE_IMPRESS, aUrl.getExtension()) )
+        if( RecentDocsView::typeMatchesExtension(TYPE_IMPRESS, aURLObj.getExtension()) )
         {
             // Swap width and height (PAPER_SCREEN_4_3 definition make it needed)
             PaperInfo aInfo(PAPER_SCREEN_4_3);
@@ -86,7 +86,7 @@ void RecentDocsViewItem::setEditTitle (bool edit, bool bChangeFocus)
 
 OUString RecentDocsViewItem::getHelpText() const
 {
-    return maURL;
+    return m_sHelpText;
 }
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
commit adf932c6569fe9b50883b54f8b959968188476d3
Author: Zolnai Tamás <tamas.zolnai at collabora.com>
Date:   Fri Jan 10 03:21:27 2014 +0100

    fdo#72420 Startcenter: help button point to local/wiki help, ui part
    
    Change-Id: I7ac4b51868d1a5828c810b1ac629d5a56ffb6f50

diff --git a/sfx2/source/dialog/backingwindow.cxx b/sfx2/source/dialog/backingwindow.cxx
index ea3dd21..60ce65f 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -230,7 +230,6 @@ void BackingWindow::initControls()
     setupButton( mpImpressAllButton );
     setupButton( mpMathAllButton );
 
-    mpHelpButton->SetClickHdl(LINK(this, BackingWindow, ExtLinkClickHdl));
     mpExtensionsButton->SetClickHdl(LINK(this, BackingWindow, ExtLinkClickHdl));
 
     // setup nice colors
@@ -360,8 +359,6 @@ IMPL_LINK(BackingWindow, ExtLinkClickHdl, Button*, pButton)
 
     if (pButton == mpExtensionsButton)
         aNode = "AddFeatureURL";
-    else if (pButton == mpHelpButton)
-        aNode = "InfoURL";
 
     if (!aNode.isEmpty())
     {
diff --git a/sfx2/uiconfig/ui/startcenter.ui b/sfx2/uiconfig/ui/startcenter.ui
index 831e1bf..4e0e04b 100644
--- a/sfx2/uiconfig/ui/startcenter.ui
+++ b/sfx2/uiconfig/ui/startcenter.ui
@@ -260,13 +260,14 @@
                         <property name="orientation">vertical</property>
                         <child>
                           <object class="GtkButton" id="help">
-                            <property name="label" translatable="yes">_Help</property>
+                            <property name="label">gtk-help</property>
                             <property name="visible">True</property>
                             <property name="can_focus">True</property>
                             <property name="receives_default">True</property>
                             <property name="has_tooltip">True</property>
                             <property name="relief">none</property>
                             <property name="use_underline">True</property>
+                            <property name="use_stock">True</property>
                           </object>
                           <packing>
                             <property name="expand">False</property>


More information about the Libreoffice-commits mailing list