Skip to content

Commit 1197959

Browse files
committed
Merge branch 'master' of github.com:qgis/Quantum-GIS
2 parents 6fbad32 + a6746f1 commit 1197959

File tree

6 files changed

+17
-6
lines changed

6 files changed

+17
-6
lines changed

src/app/qgisapp.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5286,6 +5286,10 @@ void QgisApp::removePluginDatabaseMenu( QString name, QAction* action )
52865286
{
52875287
QMenu* menu = getDatabaseMenu( name );
52885288
menu->removeAction( action );
5289+
if ( menu->actions().count() == 0 )
5290+
{
5291+
mDatabaseMenu->removeAction( menu->menuAction() );
5292+
}
52895293

52905294
// remove the Database menu from the menuBar if there are no more actions
52915295
if ( mDatabaseMenu->actions().count() > 0 )

src/mapserver/qgswmsserver.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1776,6 +1776,12 @@ bool QgsWMSServer::testFilterStringSafety( const QString& filter ) const
17761776

17771777
//numeric strings need to be quoted once either with single or with double quotes
17781778

1779+
//empty strings are ok
1780+
if ( *tokenIt == "''" )
1781+
{
1782+
continue;
1783+
}
1784+
17791785
//single quote
17801786
if ( tokenIt->size() > 2
17811787
&& ( *tokenIt )[0] == QChar( '\'' )

src/plugins/offline_editing/offline_editing_plugin.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,9 +115,9 @@ void QgsOfflineEditingPlugin::unload()
115115
disconnect( QgsProject::instance(), SIGNAL( writeProject( QDomDocument & ) ), this, SLOT( updateActions() ) );
116116

117117
// remove the GUI
118-
mQGisIface->removePluginDatabaseMenu( "&Offline Editing", mActionConvertProject );
118+
mQGisIface->removePluginDatabaseMenu( tr( "&Offline Editing" ), mActionConvertProject );
119119
mQGisIface->removeToolBarIcon( mActionConvertProject );
120-
mQGisIface->removePluginDatabaseMenu( "&Offline Editing", mActionSynchronize );
120+
mQGisIface->removePluginDatabaseMenu( tr( "&Offline Editing" ), mActionSynchronize );
121121
mQGisIface->removeToolBarIcon( mActionSynchronize );
122122
delete mActionConvertProject;
123123
delete mActionSynchronize;

src/plugins/oracle_raster/qgsoracle_plugin.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ void QgsOraclePlugin::initGui()
5858
// Connect the action to the run
5959
connect( mQActionPointer, SIGNAL( triggered() ), this, SLOT( run() ) );
6060
// Add the icon to the toolbar
61-
mQGisIface->addToolBarIcon( mQActionPointer );
61+
mQGisIface->layerToolBar()->addAction( mQActionPointer );
6262
mQGisIface->insertAddLayerAction( mQActionPointer );
6363

6464
}
@@ -87,7 +87,7 @@ void QgsOraclePlugin::run()
8787
void QgsOraclePlugin::unload()
8888
{
8989
// remove the GUI
90-
mQGisIface->removeToolBarIcon( mQActionPointer );
90+
mQGisIface->layerToolBar()->removeAction( mQActionPointer );
9191
mQGisIface->removeAddLayerAction( mQActionPointer );
9292
delete mQActionPointer;
9393
}

src/plugins/oracle_raster/qgsoracle_plugin.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
// Qt Includes
2020
#include <QObject>
2121
#include <QAction>
22+
#include <QToolBar>
2223

2324
// QGIS Includes
2425
#include <qgisplugin.h>

src/plugins/spit/qgsspitplugin.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ void QgsSpitPlugin::initGui()
7070
connect( spitAction, SIGNAL( triggered() ), this, SLOT( spit() ) );
7171
// Add the icon to the toolbar and to the plugin menu
7272
qI->addToolBarIcon( spitAction );
73-
qI->addPluginToMenu( tr( "&Spit" ), spitAction );
73+
qI->addPluginToDatabaseMenu( tr( "&Spit" ), spitAction );
7474

7575
// this is called when the icon theme is changed
7676
connect( qI, SIGNAL( currentThemeChanged( QString ) ), this, SLOT( setCurrentTheme( QString ) ) );
@@ -90,7 +90,7 @@ void QgsSpitPlugin::unload()
9090
{
9191
// remove the GUI
9292
qI->removeToolBarIcon( spitAction );
93-
qI->removePluginMenu( tr( "&Spit" ), spitAction );
93+
qI->removePluginDatabaseMenu( tr( "&Spit" ), spitAction );
9494
delete spitAction;
9595
}
9696

0 commit comments

Comments
 (0)