SVN Commit by andreas: r4438 - in trunk/pgadmin3/src: agent base frm include main schema - Mailing list pgadmin-hackers

From svn@pgadmin.org
Subject SVN Commit by andreas: r4438 - in trunk/pgadmin3/src: agent base frm include main schema
Date
Msg-id 200509101952.j8AJqix5012212@developer.pgadmin.org
Whole thread Raw
List pgadmin-hackers
Author: andreas
Date: 2005-09-10 20:52:44 +0100 (Sat, 10 Sep 2005)
New Revision: 4438

Modified:
   trunk/pgadmin3/src/agent/dlgSchedule.cpp
   trunk/pgadmin3/src/agent/pgaJob.cpp
   trunk/pgadmin3/src/agent/pgaStep.cpp
   trunk/pgadmin3/src/base/base.cpp
   trunk/pgadmin3/src/base/factory.cpp
   trunk/pgadmin3/src/frm/frmConfig.cpp
   trunk/pgadmin3/src/frm/frmHbaConfig.cpp
   trunk/pgadmin3/src/frm/frmMain.cpp
   trunk/pgadmin3/src/include/pgOperatorClass.h
   trunk/pgadmin3/src/main/events.cpp
   trunk/pgadmin3/src/schema/pgServer.cpp
   trunk/pgadmin3/src/schema/pgTable.cpp
Log:
gcc warning fixes

Modified: trunk/pgadmin3/src/agent/dlgSchedule.cpp
===================================================================
--- trunk/pgadmin3/src/agent/dlgSchedule.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/agent/dlgSchedule.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -133,7 +133,7 @@

         wxString id, dateToken, timeToken;
         wxDateTime val;
-        long pos;
+        long pos=0;
         wxStringTokenizer tkz(schedule->GetExceptions(), wxT("|"));

         while (tkz.HasMoreTokens() )

Modified: trunk/pgadmin3/src/agent/pgaJob.cpp
===================================================================
--- trunk/pgadmin3/src/agent/pgaJob.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/agent/pgaJob.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -193,7 +193,7 @@

     if (statistics)
     {
-        wxLogInfo(wxT("Displaying statistics for job %s"), GetFullIdentifier());
+        wxLogInfo(wxT("Displaying statistics for job %s"), GetFullIdentifier().c_str());

         // Add the statistics view columns
         statistics->ClearAll();

Modified: trunk/pgadmin3/src/agent/pgaStep.cpp
===================================================================
--- trunk/pgadmin3/src/agent/pgaStep.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/agent/pgaStep.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -160,7 +160,7 @@

     if (statistics)
     {
-        wxLogInfo(wxT("Displaying statistics for job %s"), GetFullIdentifier());
+        wxLogInfo(wxT("Displaying statistics for job %s"), GetFullIdentifier().c_str());

         // Add the statistics view columns
         statistics->ClearAll();

Modified: trunk/pgadmin3/src/base/base.cpp
===================================================================
--- trunk/pgadmin3/src/base/base.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/base/base.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -127,7 +127,7 @@
 wxString NumToStr(wxLongLong value)
 {
     wxString str;
-    str.Printf(wxT("%") wxLongLongFmtSpec wxT("d"), value);
+    str.Printf(wxT("%") wxLongLongFmtSpec wxT("d"), value.GetValue());
     return str;
 }


Modified: trunk/pgadmin3/src/base/factory.cpp
===================================================================
--- trunk/pgadmin3/src/base/factory.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/base/factory.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -151,6 +151,7 @@
         wxMenuItem *item=menu->Append(MNU_NEW+GetId(), GetNewString(), GetNewLongString());
         if (image)
         {
+            (void)item;
             // doesn't work?
             // item->SetBitmap(wxBitmap(image));
         }

Modified: trunk/pgadmin3/src/frm/frmConfig.cpp
===================================================================
--- trunk/pgadmin3/src/frm/frmConfig.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/frm/frmConfig.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -150,6 +150,8 @@

 #ifdef __WXMAC__
     wxApp::s_macAboutMenuItemId = af->GetId();
+#else
+    (void)af;
 #endif

     menuFactories->RegisterMenu(this, wxCommandEventHandler(pgFrame::OnAction));

Modified: trunk/pgadmin3/src/frm/frmHbaConfig.cpp
===================================================================
--- trunk/pgadmin3/src/frm/frmHbaConfig.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/frm/frmHbaConfig.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -29,9 +29,6 @@

 #define CTL_CFGVIEW 345

-#include "images/pgAdmin3.xpm"
-#include "images/elephant32.xpm"
-
 #include <wx/arrimpl.cpp>
 WX_DEFINE_OBJARRAY(pgHbaConfigLineArray);


Modified: trunk/pgadmin3/src/frm/frmMain.cpp
===================================================================
--- trunk/pgadmin3/src/frm/frmMain.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/frm/frmMain.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -221,6 +221,9 @@
     wxApp::s_macPreferencesMenuItemId = optFact->GetId();
     wxApp::s_macExitMenuItemId = MNU_EXIT;
     wxApp::s_macAboutMenuItemId = abFact->GetId();
+#else
+    (void)optFact;
+    (void)abFact;
 #endif



Modified: trunk/pgadmin3/src/include/pgOperatorClass.h
===================================================================
--- trunk/pgadmin3/src/include/pgOperatorClass.h    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/include/pgOperatorClass.h    2005-09-10 19:52:44 UTC (rev 4438)
@@ -62,4 +62,4 @@
     bool opcDefault;
 };

-#endif
\ No newline at end of file
+#endif

Modified: trunk/pgadmin3/src/main/events.cpp
===================================================================
--- trunk/pgadmin3/src/main/events.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/main/events.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -277,7 +277,6 @@
 {
     browser->RemoveDummyChild(data);

-    int type = data->GetType();
     pgServer *server=0;



Modified: trunk/pgadmin3/src/schema/pgServer.cpp
===================================================================
--- trunk/pgadmin3/src/schema/pgServer.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/schema/pgServer.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -897,7 +897,7 @@

     long loop, port, ssl=0;
     wxString key, servername, description, database, username, lastDatabase, lastSchema, storePwd, serviceID;
-    pgServer *server;
+    pgServer *server=0;

     wxArrayString servicedServers;

@@ -1024,7 +1024,7 @@
 #include "images/serverbad-sm.xpm"

 pgServerFactory::pgServerFactory()
-: pgaFactory(__("Server"), _("New Server Registration"), _("Create a new Server registration."), server_xpm)
+: pgaFactory(__("Server"), _("New Server Registration"), _("Create a new Server registration."), server_xpm,
server_sm_xpm)
 {
     metaType = PGM_SERVER;
     closedId = addIcon(serverbad_xpm);

Modified: trunk/pgadmin3/src/schema/pgTable.cpp
===================================================================
--- trunk/pgadmin3/src/schema/pgTable.cpp    2005-09-10 18:15:20 UTC (rev 4437)
+++ trunk/pgadmin3/src/schema/pgTable.cpp    2005-09-10 19:52:44 UTC (rev 4438)
@@ -472,8 +472,8 @@
             canHint = (rows >= 20);
         else
         {
-            wxULongLong quot = rows*10 / estimatedRows;
-            canHint = ((quot > 12 || quot < 8) && (rows+20 < estimatedRows || rows > estimatedRows+20));
+            wxULongLong quot = (wxLongLong_t)(rows.GetValue() *10. / estimatedRows);
+            canHint = ((quot > 12 || quot < 8) && (rows.GetValue() < estimatedRows-20. || rows.GetValue() >
estimatedRows+20.));
         }
     }
     else if (estimatedRows == 1000)


pgadmin-hackers by date:

Previous
From: Andreas Pflug
Date:
Subject: Re: suse makefile?
Next
From: svn@pgadmin.org
Date:
Subject: SVN Commit by andreas: r4439 - trunk/pgadmin3/src/schema