[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [kolourpaint/Applications/16.12] /: Use KStandardGuiItem::overwrite()
From:       Pino Toscano <pino () kde ! org>
Date:       2016-12-04 14:17:16
Message-ID: E1cDXbQ-0000LD-FE () code ! kde ! org
[Download RAW message or body]

Git commit 20b9078c683df3207ad811f7bcd7879918f1556b by Pino Toscano.
Committed on 04/12/2016 at 14:16.
Pushed by pino into branch 'Applications/16.12'.

Use KStandardGuiItem::overwrite()

... instead of creating the KGuiItem from scratch

M  +1    -1    document/kpDocument_Save.cpp
M  +1    -1    lgpl/generic/kpColorCollection.cpp

https://commits.kde.org/kolourpaint/20b9078c683df3207ad811f7bcd7879918f1556b

diff --git a/document/kpDocument_Save.cpp b/document/kpDocument_Save.cpp
index 0fe3baf..0c63803 100644
--- a/document/kpDocument_Save.cpp
+++ b/document/kpDocument_Save.cpp
@@ -333,7 +333,7 @@ bool kpDocument::savePixmapToFile (const QImage &pixmap,
                   "Do you want to overwrite it?",
                   kpUrlFormatter::PrettyFilename (url)),
             QString(),
-            KGuiItem(i18n ("Overwrite")));
+            KStandardGuiItem::overwrite ());
 
         if (result != KMessageBox::Continue)
         {
diff --git a/lgpl/generic/kpColorCollection.cpp b/lgpl/generic/kpColorCollection.cpp
index 30e674c..69aa0a0 100644
--- a/lgpl/generic/kpColorCollection.cpp
+++ b/lgpl/generic/kpColorCollection.cpp
@@ -296,7 +296,7 @@ kpColorCollection::saveAs(const QUrl &url, bool showOverwritePrompt,
                 "Do you want to overwrite it?",
                 kpUrlFormatter::PrettyFilename (url)),
           QString (),
-          KGuiItem (i18n ("Overwrite")));
+          KStandardGuiItem::overwrite ());
        if (result != KMessageBox::Continue)
           return false;
    }
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic