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

List:       kde-commits
Subject:    KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets
From:       Tiger Dong <idlecat511 () gmail ! com>
Date:       2009-12-28 11:06:56
Message-ID: 1261998416.869197.13247.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1066928 by tdong:

[GGL] fix warnings
[GGL] replace PopOutMainViewDecorator with PopoutDecorator. The latter doesn't have \
caption.


 M  +1 -0      CMakeLists.txt  
 M  +1 -1      floating_decorator.cpp  
 M  +4 -1      ggl_applet_script.cpp  
 M  +4 -0      ggl_applet_script.h  
 M  +1 -1      ggl_package.cpp  
 M  +2 -2      panel_decorator.cpp  
 M  +5 -4      plasma_host.cpp  
 M  +10 -6     plasma_view_host.cpp  
 M  +1 -1      plasma_view_host.h  
 M  +2 -0      plasma_view_host_internal.h  
 A             popout_decorator.cpp   [License: UNKNOWN]
 A             popout_decorator.h   [License: UNKNOWN]


--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/CMakeLists.txt \
#1066927:1066928 @@ -41,6 +41,7 @@
   plasma_view_host.cpp
   panel_decorator.cpp
   floating_decorator.cpp
+  popout_decorator.cpp
   )
 
 # Now make sure all files get to the right place
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/floating_decorator.cpp \
#1066927:1066928 @@ -13,6 +13,7 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 */
+#include "floating_decorator.h"
 
 #include <QtGui/QMessageBox>
 
@@ -24,7 +25,6 @@
 #include <ggadget/qt/qt_view_widget.h>
 
 #include <Plasma/Applet>
-#include "floating_decorator.h"
 
 namespace ggadget {
 
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/ggl_applet_script.cpp \
#1066927:1066928 @@ -13,6 +13,7 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 */
+#include "ggl_applet_script.h"
 
 #include <sys/time.h>
 #include <time.h>
@@ -48,7 +49,6 @@
 #include <ggadget/decorated_view_host.h>
 #include "plasma_host.h"
 #include "ggl_extensions.h"
-#include "ggl_applet_script.h"
 
 K_EXPORT_PLASMA_APPLETSCRIPTENGINE(googlegadget, GglAppletScript)
 
@@ -130,6 +130,9 @@
 void GglAppletScript::paintInterface(QPainter *p,
                                      const QStyleOptionGraphicsItem *option,
                                      const QRect &contentsRect) {
+  Q_UNUSED(p);
+  Q_UNUSED(option);
+  Q_UNUSED(contentsRect);
 #if 0
   QRect r = contentsRect;
   p->setPen(QColor(0, 0, 255));
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/ggl_applet_script.h \
#1066927:1066928 @@ -20,9 +20,13 @@
 #include <Plasma/AppletScript>
 
 namespace ggadget {
+  class Gadget;
   class PlasmaHost;
   class DecoratedViewHost;
   class ViewHostInterface;
+  namespace qt {
+    class QtViewWidget;
+  }
 }
 
 namespace Plasma {
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/ggl_package.cpp \
#1066927:1066928 @@ -13,6 +13,7 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 */
+#include "ggl_package.h"
 
 #include <QtCore/QDir>
 #include <QtCore/QFile>
@@ -34,7 +35,6 @@
 #include <ggadget/qt/qt_view_host.h>
 #include <ggadget/qt/utilities.h>
 #include "ggl_extensions.h"
-#include "ggl_package.h"
 
 using namespace ggadget;
 
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/panel_decorator.cpp \
#1066927:1066928 @@ -13,6 +13,7 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 */
+#include "panel_decorator.h"
 
 #include <QtGui/QMessageBox>
 
@@ -24,7 +25,6 @@
 #include <ggadget/qt/qt_view_widget.h>
 
 #include <Plasma/Applet>
-#include "panel_decorator.h"
 
 namespace ggadget {
 
@@ -141,7 +141,7 @@
   }
 }
 
-void PanelDecorator::SetResizable(ViewInterface::ResizableMode resizable) {
+void PanelDecorator::SetResizable(ViewInterface::ResizableMode) {
   View::SetResizable(RESIZABLE_FALSE);
 }
 
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/plasma_host.cpp \
#1066927:1066928 @@ -13,6 +13,7 @@
   See the License for the specific language governing permissions and
   limitations under the License.
 */
+#include "plasma_host.h"
 
 #include <string>
 #include <QtGui/QGraphicsWidget>
@@ -24,7 +25,6 @@
 #include <ggadget/gadget_consts.h>
 #include <ggadget/decorated_view_host.h>
 #include <ggadget/docked_main_view_decorator.h>
-#include <ggadget/popout_main_view_decorator.h>
 #include <ggadget/details_view_decorator.h>
 #include <ggadget/permissions.h>
 #include <ggadget/qt/utilities.h>
@@ -33,8 +33,8 @@
 
 #include <Plasma/Applet>
 #include "plasma_view_host.h"
-#include "plasma_host.h"
 #include "panel_decorator.h"
+#include "popout_decorator.h"
 #include "floating_decorator.h"
 
 namespace ggadget {
@@ -72,8 +72,7 @@
     if (child) {
       PlasmaViewHost *vh = new PlasmaViewHost(
               info, ViewHostInterface::VIEW_HOST_MAIN, true);
-      PopOutMainViewDecorator *view_decorator =
-          new PopOutMainViewDecorator(vh);
+      PopOutDecorator *view_decorator = new PopOutDecorator(vh);
       DecoratedViewHost *dvh = new DecoratedViewHost(view_decorator);
       view_decorator->ConnectOnClose(
           NewSlot(this, &Private::onClosePopOutViewHandler));
@@ -176,6 +175,8 @@
 
 void PlasmaHost::RemoveGadget(Gadget *gadget, bool save_data) {
   // Please close me through plasma's button
+  Q_UNUSED(gadget);
+  Q_UNUSED(save_data);
 }
 
 bool PlasmaHost::LoadFont(const char *filename) {
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/plasma_view_host.cpp \
#1066927:1066928 @@ -14,14 +14,17 @@
   limitations under the License.
 */
 
+#include "plasma_view_host.h"
+
 #include <sys/time.h>
 
-#include <KMessageBox>
 #include <QtGui/QGraphicsProxyWidget>
 #include <QtGui/QGraphicsLinearLayout>
 #include <QtGui/QToolTip>
 
 #include <KInputDialog>
+#include <KMessageBox>
+
 #include <ggadget/file_manager_interface.h>
 #include <ggadget/gadget_consts.h>
 #include <ggadget/logger.h>
@@ -32,7 +35,6 @@
 #include <ggadget/script_runtime_manager.h>
 #include <ggadget/qt/qt_graphics.h>
 #include <ggadget/qt/utilities.h>
-#include "plasma_view_host.h"
 #include "plasma_view_host_internal.h"
 
 #include <Plasma/Applet>
@@ -89,9 +91,6 @@
   d->queueResize();
 }
 
-void PlasmaViewHost::EnableInputShapeMask(bool enable) {
-}
-
 void PlasmaViewHost::SetResizable(ViewInterface::ResizableMode mode) {
   if (d->type_ != ViewHostInterface::VIEW_HOST_MAIN || d->is_popout_ ||
       !d->info->applet)
@@ -111,6 +110,7 @@
 
 void PlasmaViewHost::SetShowCaptionAlways(bool always) {
   // TODO:
+  Q_UNUSED(always);
 }
 
 void PlasmaViewHost::SetCursor(ggadget::ViewInterface::CursorType type) {
@@ -129,6 +129,9 @@
 void PlasmaViewHost::ShowTooltipAtPosition(const std::string &tooltip,
                                            double x, double y) {
   // TODO:
+  Q_UNUSED(tooltip);
+  Q_UNUSED(x);
+  Q_UNUSED(y);
 }
 
 bool PlasmaViewHost::ShowView(bool modal, int flags,
@@ -169,7 +172,8 @@
                                    const char *message,
                                    const char *default_value) {
   QString s = KInputDialog::getText(view->GetCaption().c_str(),
-                                   message);
+                                    message,
+                                    default_value);
   return s.toUtf8().data();
 }
 
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/plasma_view_host.h \
#1066927:1066928 @@ -60,7 +60,7 @@
       double x, double y, double *view_x, double *view_y) const;
   virtual void QueueDraw();
   virtual void QueueResize();
-  virtual void EnableInputShapeMask(bool enable);
+  virtual void EnableInputShapeMask(bool enable) { Q_UNUSED(enable); }
   virtual void SetResizable(ViewInterface::ResizableMode mode);
   virtual void SetCaption(const std::string &caption);
   virtual void SetShowCaptionAlways(bool always);
--- trunk/KDE/kdebase/workspace/plasma/generic/scriptengines/google_gadgets/plasma_view_host_internal.h \
#1066927:1066928 @@ -61,6 +61,8 @@
    *    - popouted main view and details view: Shown in QtViewWidget
    */
   bool showView(bool modal, int flags, Slot1<bool, int> *feedback_handler) {
+    Q_UNUSED(modal);
+    Q_UNUSED(flags);
     ASSERT(view_);
     if (feedback_handler_ && feedback_handler_ != feedback_handler)
       delete feedback_handler_;


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

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