mirror of
https://github.com/sqlitebrowser/sqlitebrowser.git
synced 2026-01-21 03:21:43 -06:00
Move form data and code for Browse Data tab into a separate widget class
This adds a new widget called TableBrowser which does everything the Browse Data tab did before. All the UI data and all the code related to this tab is moved into the new widget class. The main window now simply uses the new widget instead of implementing all this stuff itself. I mainly see three benefits from this change: 1) The main window class becomes smaller and starts looking less like a master class which manages all of the application. This should make it easier for new developers to find their way around the code. 2) A better separation of the table browser and the remaining main window makes it clearer which class class is responsible for what. Again this makes it easier to maintain the code when it grows. 3) If we ever want to have split views, multiple Browse Data tabs, or something similar this is an absolute prerequisite. This commit obviously changes a lot of code. So be prepared for unintended changes and consider doing some extra testing. See issue #1972.
This commit is contained in:
@@ -176,6 +176,7 @@ set(SQLB_MOC_HDR
|
||||
src/RunSql.h
|
||||
src/ProxyDialog.h
|
||||
src/SelectItemsPopup.h
|
||||
src/TableBrowser.h
|
||||
)
|
||||
|
||||
set(SQLB_SRC
|
||||
@@ -232,6 +233,7 @@ set(SQLB_SRC
|
||||
src/ProxyDialog.cpp
|
||||
src/IconCache.cpp
|
||||
src/SelectItemsPopup.cpp
|
||||
src/TableBrowser.cpp
|
||||
)
|
||||
|
||||
set(SQLB_FORMS
|
||||
@@ -257,6 +259,7 @@ set(SQLB_FORMS
|
||||
src/CondFormatManager.ui
|
||||
src/ProxyDialog.ui
|
||||
src/SelectItemsPopup.ui
|
||||
src/TableBrowser.ui
|
||||
)
|
||||
|
||||
set(SQLB_RESOURCES
|
||||
|
||||
@@ -5,6 +5,7 @@
|
||||
#include <QLibraryInfo>
|
||||
#include <QLocale>
|
||||
#include <QDebug>
|
||||
#include <QAction>
|
||||
|
||||
#include "Application.h"
|
||||
#include "MainWindow.h"
|
||||
@@ -174,7 +175,7 @@ Application::Application(int& argc, char** argv) :
|
||||
|
||||
// Jump to table if the -t/--table parameter was set
|
||||
if(!tableToBrowse.isEmpty())
|
||||
m_mainWindow->switchToBrowseDataTab(tableToBrowse);
|
||||
m_mainWindow->switchToBrowseDataTab(sqlb::ObjectIdentifier("main", tableToBrowse.toStdString()));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -208,3 +209,26 @@ QString Application::versionString()
|
||||
return QString("%1").arg(APP_VERSION);
|
||||
#endif
|
||||
}
|
||||
|
||||
// Functions for documenting the shortcuts in the user interface using native names
|
||||
static QString shortcutsTip(const QList<QKeySequence>& keys)
|
||||
{
|
||||
QString tip("");
|
||||
|
||||
if (!keys.isEmpty()) {
|
||||
tip = " [";
|
||||
|
||||
for (auto shortcut : keys)
|
||||
tip.append(shortcut.toString(QKeySequence::NativeText) + ", ");
|
||||
tip.chop(2);
|
||||
|
||||
tip.append("]");
|
||||
}
|
||||
return tip;
|
||||
}
|
||||
|
||||
void addShortcutsTooltip(QAction* action, const QList<QKeySequence>& extraKeys)
|
||||
{
|
||||
if (!action->shortcuts().isEmpty() || !extraKeys.isEmpty())
|
||||
action->setToolTip(action->toolTip() + shortcutsTip(action->shortcuts() + extraKeys));
|
||||
}
|
||||
|
||||
@@ -2,9 +2,12 @@
|
||||
#define APPLICATION_H
|
||||
|
||||
#include <QApplication>
|
||||
#include <QKeySequence>
|
||||
|
||||
class QAction;
|
||||
class QTranslator;
|
||||
|
||||
class MainWindow;
|
||||
class QTranslator;
|
||||
|
||||
class Application : public QApplication
|
||||
{
|
||||
@@ -30,4 +33,6 @@ private:
|
||||
QTranslator* m_translatorApp;
|
||||
};
|
||||
|
||||
void addShortcutsTooltip(QAction* action, const QList<QKeySequence>& extraKeys = QList<QKeySequence>());
|
||||
|
||||
#endif
|
||||
|
||||
1162
src/MainWindow.cpp
1162
src/MainWindow.cpp
File diff suppressed because it is too large
Load Diff
122
src/MainWindow.h
122
src/MainWindow.h
@@ -2,26 +2,22 @@
|
||||
#define MAINWINDOW_H
|
||||
|
||||
#include "sqlitedb.h"
|
||||
#include "PlotDock.h"
|
||||
#include "Palette.h"
|
||||
#include "CondFormat.h"
|
||||
#include "sql/Query.h"
|
||||
|
||||
#include <memory>
|
||||
#include <QMainWindow>
|
||||
#include <QMap>
|
||||
|
||||
class EditDialog;
|
||||
class SqliteTableModel;
|
||||
class BrowseDataTableSettings;
|
||||
class DbStructureModel;
|
||||
class RemoteDock;
|
||||
class RemoteDatabase;
|
||||
class FindReplaceDialog;
|
||||
class EditDialog;
|
||||
class ExtendedTableWidget;
|
||||
class FindReplaceDialog;
|
||||
class PlotDock;
|
||||
class RemoteDatabase;
|
||||
class RemoteDock;
|
||||
class RunSql;
|
||||
class SqliteTableModel;
|
||||
|
||||
class QDragEnterEvent;
|
||||
class QIntValidator;
|
||||
class QModelIndex;
|
||||
class QLabel;
|
||||
class QPersistentModelIndex;
|
||||
@@ -31,55 +27,6 @@ namespace Ui {
|
||||
class MainWindow;
|
||||
}
|
||||
|
||||
struct BrowseDataTableSettings
|
||||
{
|
||||
sqlb::Query query; // NOTE: We only store the sort order in here (for now)
|
||||
QMap<int, int> columnWidths;
|
||||
QMap<int, QString> filterValues;
|
||||
QMap<int, std::vector<CondFormat>> condFormats;
|
||||
QMap<int, QString> displayFormats;
|
||||
bool showRowid;
|
||||
QString encoding;
|
||||
QString plotXAxis;
|
||||
QMap<QString, PlotDock::PlotSettings> plotYAxes;
|
||||
QString unlockViewPk;
|
||||
QMap<int, bool> hiddenColumns;
|
||||
|
||||
BrowseDataTableSettings() :
|
||||
showRowid(false)
|
||||
{
|
||||
}
|
||||
|
||||
friend QDataStream& operator>>(QDataStream& stream, BrowseDataTableSettings& object)
|
||||
{
|
||||
int sortOrderIndex, sortOrderMode;
|
||||
stream >> sortOrderIndex;
|
||||
stream >> sortOrderMode;
|
||||
object.query.orderBy().emplace_back(sortOrderIndex, sortOrderMode == Qt::AscendingOrder ? sqlb::Ascending : sqlb::Descending);
|
||||
stream >> object.columnWidths;
|
||||
stream >> object.filterValues;
|
||||
stream >> object.displayFormats;
|
||||
stream >> object.showRowid;
|
||||
stream >> object.encoding;
|
||||
|
||||
// Versions pre 3.10.0 didn't store the following information in their project files.
|
||||
// To be absolutely sure that nothing strange happens when we read past the stream for
|
||||
// those cases, check for the end of the stream here.
|
||||
if(stream.atEnd())
|
||||
return stream;
|
||||
stream >> object.plotXAxis;
|
||||
stream >> object.plotYAxes;
|
||||
stream >> object.unlockViewPk;
|
||||
|
||||
// Project files from versions before 3.11.0 didn't have these fields
|
||||
if(stream.atEnd())
|
||||
return stream;
|
||||
stream >> object.hiddenColumns;
|
||||
|
||||
return stream;
|
||||
}
|
||||
};
|
||||
|
||||
class MainWindow : public QMainWindow
|
||||
{
|
||||
Q_OBJECT
|
||||
@@ -118,21 +65,14 @@ private:
|
||||
|
||||
DBBrowserDB db;
|
||||
|
||||
/// the table model used in the "Browse Data" page (re-used and
|
||||
/// re-initialized when switching to another table)
|
||||
SqliteTableModel* m_browseTableModel;
|
||||
|
||||
SqliteTableModel* m_currentTabTableModel;
|
||||
|
||||
QMenu* popupTableMenu;
|
||||
QMenu* popupSchemaDockMenu;
|
||||
QMenu* recentFilesMenu;
|
||||
QMenu* popupOpenDbMenu;
|
||||
QMenu* popupNewRecordMenu;
|
||||
QMenu* popupSaveSqlFileMenu;
|
||||
QMenu* popupSaveSqlResultsMenu;
|
||||
QMenu* popupSaveFilterAsMenu;
|
||||
QMenu* popupBrowseDataHeaderMenu;
|
||||
|
||||
QLabel* statusEncodingLabel;
|
||||
QLabel* statusEncryptionLabel;
|
||||
@@ -146,8 +86,6 @@ private:
|
||||
QAction *recentFileActs[MaxRecentFiles];
|
||||
QAction *recentSeparatorAct;
|
||||
|
||||
QMap<sqlb::ObjectIdentifier, BrowseDataTableSettings> browseTableSettings;
|
||||
|
||||
RemoteDatabase* m_remoteDb;
|
||||
|
||||
EditDialog* editDock;
|
||||
@@ -155,12 +93,6 @@ private:
|
||||
RemoteDock* remoteDock;
|
||||
FindReplaceDialog* findReplaceDialog;
|
||||
|
||||
QIntValidator* gotoValidator;
|
||||
|
||||
QString defaultBrowseTableEncoding;
|
||||
|
||||
Palette m_condFormatPalette;
|
||||
|
||||
std::unique_ptr<RunSql> execute_sql_worker;
|
||||
|
||||
QString defaultOpenTabs;
|
||||
@@ -176,15 +108,9 @@ private:
|
||||
void setCurrentFile(const QString& fileName);
|
||||
void addToRecentFilesMenu(const QString& filename, bool read_only = false);
|
||||
void activateFields(bool enable = true);
|
||||
void enableEditing(bool enable_edit);
|
||||
void saveAsView(QString query);
|
||||
void duplicateRecord(int currentRow);
|
||||
void selectTableLine(int lineToSelect);
|
||||
void attachPlot(ExtendedTableWidget* tableWidget, SqliteTableModel* model, BrowseDataTableSettings* settings = nullptr, bool keepOrResetSelection = true);
|
||||
|
||||
sqlb::ObjectIdentifier currentlyBrowsedTableName() const;
|
||||
|
||||
void applyBrowseTableSettings(const BrowseDataTableSettings& storedData, bool skipFilters = false);
|
||||
void toggleTabVisible(QWidget* tabWidget, bool show);
|
||||
void restoreOpenTabs(QString tabs);
|
||||
QString saveOpenTabs();
|
||||
@@ -204,12 +130,10 @@ public slots:
|
||||
void logSql(const QString &sql, int msgtype);
|
||||
void dbState(bool dirty);
|
||||
void refresh();
|
||||
void jumpToRow(const sqlb::ObjectIdentifier& table, QString column, const QByteArray& value);
|
||||
void switchToBrowseDataTab(QString tableToBrowse = QString());
|
||||
void switchToBrowseDataTab(sqlb::ObjectIdentifier tableToBrowse = sqlb::ObjectIdentifier());
|
||||
void populateStructure(const QString& old_table = QString());
|
||||
void reloadSettings();
|
||||
|
||||
|
||||
private slots:
|
||||
void createTreeContextMenu(const QPoint & qPoint);
|
||||
void createSchemaDockContextMenu(const QPoint & qPoint);
|
||||
@@ -217,17 +141,7 @@ private slots:
|
||||
void fileNew();
|
||||
void fileNewInMemoryDatabase();
|
||||
void populateTable();
|
||||
void clearTableBrowser();
|
||||
bool fileClose();
|
||||
void addRecord();
|
||||
void insertValues();
|
||||
void deleteRecord();
|
||||
void navigatePrevious();
|
||||
void navigateNext();
|
||||
void navigateBegin();
|
||||
void navigateEnd();
|
||||
void navigateGoto();
|
||||
void setRecordsetLabel();
|
||||
void createTable();
|
||||
void createIndex();
|
||||
void compact();
|
||||
@@ -252,7 +166,6 @@ private slots:
|
||||
void updatePragmaUi();
|
||||
void savePragmas();
|
||||
void mainTabSelected( int tabindex );
|
||||
void browseTableHeaderClicked(int logicalindex);
|
||||
int openSqlTab(bool resetCounter = false);
|
||||
void closeSqlTab(int index, bool force = false);
|
||||
void changeSqlTab(int index);
|
||||
@@ -269,38 +182,19 @@ private slots:
|
||||
void on_actionSqlCipherFaq_triggered();
|
||||
void on_actionWebsite_triggered();
|
||||
void on_actionDonatePatreon_triggered();
|
||||
void updateBrowseDataColumnWidth(int section, int /*old_size*/, int new_size);
|
||||
bool loadProject(QString filename = QString(), bool readOnly = false);
|
||||
void saveProject();
|
||||
void saveProjectAs();
|
||||
void fileAttach(const QString& fileName = QString());
|
||||
void updateFilter(int column, const QString& value);
|
||||
void addCondFormat(int column, const QString& value);
|
||||
void clearAllCondFormats(int column);
|
||||
void editCondFormats(int column);
|
||||
void editEncryption();
|
||||
void on_actionClearFilters_triggered();
|
||||
void on_actionClearSorting_triggered();
|
||||
void copyCurrentCreateStatement();
|
||||
void showDataColumnPopupMenu(const QPoint& pos);
|
||||
void showRecordPopupMenu(const QPoint& pos);
|
||||
void editDataColumnDisplayFormat();
|
||||
void showRowidColumn(bool show, bool skipFilters = false);
|
||||
void browseDataSetTableEncoding(bool forAllTables = false);
|
||||
void browseDataSetDefaultTableEncoding();
|
||||
void fileOpenReadOnly();
|
||||
void unlockViewEditing(bool unlock, QString pk = QString());
|
||||
void hideColumns(int column = -1, bool hide = true);
|
||||
void on_actionShowAllColumns_triggered();
|
||||
void requestCollation(const QString& name, int eTextRep);
|
||||
void renameSqlTab(int index);
|
||||
void setFindFrameVisibility(bool show);
|
||||
void openFindReplaceDialog();
|
||||
void toggleSqlBlockComment();
|
||||
void openSqlPrintDialog();
|
||||
void saveFilterAsView();
|
||||
void exportFilteredTable();
|
||||
void updateInsertDeleteRecordButton();
|
||||
void runSqlNewTab(const QString& query, const QString& title);
|
||||
void printDbStructure();
|
||||
void updateDatabaseBusyStatus(bool busy, const QString& user);
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,7 @@
|
||||
#include "Settings.h"
|
||||
#include "sqlitetablemodel.h"
|
||||
#include "FileDialog.h"
|
||||
#include "MainWindow.h" // Just for BrowseDataTableSettings, not for the actual main window class
|
||||
#include "TableBrowser.h" // Just for BrowseDataTableSettings, not for the actual table browser class
|
||||
|
||||
#include <QPrinter>
|
||||
#include <QPrintPreviewDialog>
|
||||
|
||||
1108
src/TableBrowser.cpp
Normal file
1108
src/TableBrowser.cpp
Normal file
File diff suppressed because it is too large
Load Diff
173
src/TableBrowser.h
Normal file
173
src/TableBrowser.h
Normal file
@@ -0,0 +1,173 @@
|
||||
#ifndef TABLEBROWSER_H
|
||||
#define TABLEBROWSER_H
|
||||
|
||||
#include "CondFormat.h"
|
||||
#include "PlotDock.h"
|
||||
#include "sql/Query.h"
|
||||
|
||||
#include <QMap>
|
||||
#include <QModelIndex>
|
||||
#include <QWidget>
|
||||
|
||||
class DBBrowserDB;
|
||||
class ExtendedTableWidget;
|
||||
class SqliteTableModel;
|
||||
|
||||
class QAbstractItemModel;
|
||||
class QIntValidator;
|
||||
|
||||
namespace Ui {
|
||||
class TableBrowser;
|
||||
}
|
||||
|
||||
struct BrowseDataTableSettings
|
||||
{
|
||||
sqlb::Query query; // NOTE: We only store the sort order in here (for now)
|
||||
QMap<int, int> columnWidths;
|
||||
QMap<int, QString> filterValues;
|
||||
QMap<int, std::vector<CondFormat>> condFormats;
|
||||
QMap<int, QString> displayFormats;
|
||||
bool showRowid;
|
||||
QString encoding;
|
||||
QString plotXAxis;
|
||||
QMap<QString, PlotDock::PlotSettings> plotYAxes;
|
||||
QString unlockViewPk;
|
||||
QMap<int, bool> hiddenColumns;
|
||||
|
||||
BrowseDataTableSettings() :
|
||||
showRowid(false),
|
||||
unlockViewPk("_rowid_")
|
||||
{
|
||||
}
|
||||
|
||||
friend QDataStream& operator>>(QDataStream& stream, BrowseDataTableSettings& object)
|
||||
{
|
||||
int sortOrderIndex, sortOrderMode;
|
||||
stream >> sortOrderIndex;
|
||||
stream >> sortOrderMode;
|
||||
object.query.orderBy().emplace_back(sortOrderIndex, sortOrderMode == Qt::AscendingOrder ? sqlb::Ascending : sqlb::Descending);
|
||||
stream >> object.columnWidths;
|
||||
stream >> object.filterValues;
|
||||
stream >> object.displayFormats;
|
||||
stream >> object.showRowid;
|
||||
stream >> object.encoding;
|
||||
|
||||
// Versions pre 3.10.0 didn't store the following information in their project files.
|
||||
// To be absolutely sure that nothing strange happens when we read past the stream for
|
||||
// those cases, check for the end of the stream here.
|
||||
if(stream.atEnd())
|
||||
return stream;
|
||||
stream >> object.plotXAxis;
|
||||
stream >> object.plotYAxes;
|
||||
stream >> object.unlockViewPk;
|
||||
|
||||
// Project files from versions before 3.11.0 didn't have these fields
|
||||
if(stream.atEnd())
|
||||
return stream;
|
||||
stream >> object.hiddenColumns;
|
||||
|
||||
return stream;
|
||||
}
|
||||
};
|
||||
|
||||
class TableBrowser : public QWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
explicit TableBrowser(QWidget* parent = nullptr);
|
||||
~TableBrowser();
|
||||
void init(DBBrowserDB* _db);
|
||||
void reset();
|
||||
|
||||
sqlb::ObjectIdentifier currentlyBrowsedTableName() const;
|
||||
|
||||
QMap<sqlb::ObjectIdentifier, BrowseDataTableSettings> allSettings() const { return browseTableSettings; }
|
||||
BrowseDataTableSettings& settings(const sqlb::ObjectIdentifier& object);
|
||||
void setSettings(const sqlb::ObjectIdentifier& table, const BrowseDataTableSettings& data);
|
||||
|
||||
void setStructure(QAbstractItemModel* model, const QString& old_table = QString());
|
||||
void updateStructure();
|
||||
|
||||
SqliteTableModel* model() { return m_browseTableModel; }
|
||||
|
||||
QModelIndex currentIndex() const;
|
||||
|
||||
void setDefaultEncoding(const QString& encoding) { defaultBrowseTableEncoding = encoding; }
|
||||
QString defaultEncoding() const { return defaultBrowseTableEncoding; }
|
||||
|
||||
public slots:
|
||||
void setEnabled(bool enable);
|
||||
void updateTable();
|
||||
void clearFilters();
|
||||
void reloadSettings();
|
||||
void setCurrentTable(const sqlb::ObjectIdentifier& name);
|
||||
void updateRecordsetLabel();
|
||||
void jumpToRow(const sqlb::ObjectIdentifier& table, QString column, const QByteArray& value);
|
||||
|
||||
signals:
|
||||
void projectModified();
|
||||
void selectionChanged(QModelIndex index);
|
||||
void selectionChangedByDoubleClick(QModelIndex index);
|
||||
void statusMessageRequested(QString message);
|
||||
void updatePlot(ExtendedTableWidget* tableWidget, SqliteTableModel* model, BrowseDataTableSettings* settings, bool keepOrResetSelection);
|
||||
void createView(QString sql);
|
||||
void requestFileOpen(QString file);
|
||||
|
||||
private slots:
|
||||
void clearTableBrowser();
|
||||
void updateFilter(int column, const QString& value);
|
||||
void addCondFormat(int column, const QString& value);
|
||||
void clearAllCondFormats(int column);
|
||||
void editCondFormats(int column);
|
||||
void applyBrowseTableSettings(const BrowseDataTableSettings& storedData, bool skipFilters = false);
|
||||
void enableEditing(bool enable_edit);
|
||||
void showRowidColumn(bool show, bool skipFilters = false);
|
||||
void unlockViewEditing(bool unlock, QString pk = QString());
|
||||
void hideColumns(int column = -1, bool hide = true);
|
||||
void on_actionShowAllColumns_triggered();
|
||||
void updateInsertDeleteRecordButton();
|
||||
void duplicateRecord(int currentRow);
|
||||
void browseTableHeaderClicked(int logicalindex);
|
||||
void updateBrowseDataColumnWidth(int section, int /*old_size*/, int new_size);
|
||||
void showDataColumnPopupMenu(const QPoint& pos);
|
||||
void showRecordPopupMenu(const QPoint& pos);
|
||||
void addRecord();
|
||||
void insertValues();
|
||||
void deleteRecord();
|
||||
void navigatePrevious();
|
||||
void navigateNext();
|
||||
void navigateBegin();
|
||||
void navigateEnd();
|
||||
void navigateGoto();
|
||||
void selectTableLine(int lineToSelect);
|
||||
void on_actionClearFilters_triggered();
|
||||
void on_actionClearSorting_triggered();
|
||||
void editDataColumnDisplayFormat();
|
||||
void exportFilteredTable();
|
||||
void saveFilterAsView();
|
||||
void browseDataSetTableEncoding(bool forAllTables = false);
|
||||
void browseDataSetDefaultTableEncoding();
|
||||
|
||||
private:
|
||||
Ui::TableBrowser* ui;
|
||||
QIntValidator* gotoValidator;
|
||||
QMenu* popupNewRecordMenu;
|
||||
QMenu* popupSaveFilterAsMenu;
|
||||
QMenu* popupBrowseDataHeaderMenu;
|
||||
|
||||
DBBrowserDB* db;
|
||||
|
||||
QAbstractItemModel* dbStructureModel;
|
||||
|
||||
/// the table model used in the "Browse Data" page (re-used and
|
||||
/// re-initialized when switching to another table)
|
||||
SqliteTableModel* m_browseTableModel;
|
||||
|
||||
QMap<sqlb::ObjectIdentifier, BrowseDataTableSettings> browseTableSettings; // TODO This probably wants to be static as soon as we have multiple instances of this class
|
||||
QString defaultBrowseTableEncoding;
|
||||
|
||||
Palette m_condFormatPalette;
|
||||
};
|
||||
|
||||
#endif
|
||||
907
src/TableBrowser.ui
Normal file
907
src/TableBrowser.ui
Normal file
@@ -0,0 +1,907 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<ui version="4.0">
|
||||
<class>TableBrowser</class>
|
||||
<widget class="QWidget" name="TableBrowser">
|
||||
<property name="geometry">
|
||||
<rect>
|
||||
<x>0</x>
|
||||
<y>0</y>
|
||||
<width>552</width>
|
||||
<height>362</height>
|
||||
</rect>
|
||||
</property>
|
||||
<property name="windowTitle">
|
||||
<string>Browse Data</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout_2">
|
||||
<property name="leftMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="topMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="rightMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<property name="bottomMargin">
|
||||
<number>0</number>
|
||||
</property>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout">
|
||||
<item>
|
||||
<widget class="QLabel" name="label">
|
||||
<property name="text">
|
||||
<string>&Table:</string>
|
||||
</property>
|
||||
<property name="buddy">
|
||||
<cstring>comboBrowseTable</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QComboBox" name="comboBrowseTable">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>150</width>
|
||||
<height>0</height>
|
||||
</size>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Select a table to browse data</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>Use this list to select a table to be displayed in the database view</string>
|
||||
</property>
|
||||
<property name="maxVisibleItems">
|
||||
<number>30</number>
|
||||
</property>
|
||||
<property name="sizeAdjustPolicy">
|
||||
<enum>QComboBox::AdjustToContents</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolBar" name="browseToolbar">
|
||||
<property name="toolButtonStyle">
|
||||
<enum>Qt::ToolButtonIconOnly</enum>
|
||||
</property>
|
||||
<addaction name="actionRefresh"/>
|
||||
<addaction name="actionClearFilters"/>
|
||||
<addaction name="actionClearSorting"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionSaveFilterAsPopup"/>
|
||||
<addaction name="actionPrintTable"/>
|
||||
<addaction name="separator"/>
|
||||
<addaction name="actionNewRecord"/>
|
||||
<addaction name="actionDeleteRecord"/>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeType">
|
||||
<enum>QSizePolicy::MinimumExpanding</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>0</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="ExtendedTableWidget" name="dataTable">
|
||||
<property name="acceptDrops">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This is the database table view. You can do the following actions:
|
||||
- Start writing for editing inline the value.
|
||||
- Double-click any record to edit its contents in the cell editor window.
|
||||
- Alt+Del for deleting the cell content to NULL.
|
||||
- Ctrl+" for duplicating the current record.
|
||||
- Ctrl+' for copying the value from the cell above.
|
||||
- Standard selection and copy/paste operations.</string>
|
||||
</property>
|
||||
<property name="editTriggers">
|
||||
<set>QAbstractItemView::NoEditTriggers</set>
|
||||
</property>
|
||||
<property name="dragDropMode">
|
||||
<enum>QAbstractItemView::DragDrop</enum>
|
||||
</property>
|
||||
<property name="defaultDropAction">
|
||||
<enum>Qt::CopyAction</enum>
|
||||
</property>
|
||||
<property name="selectionMode">
|
||||
<enum>QAbstractItemView::ContiguousSelection</enum>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_2">
|
||||
<item>
|
||||
<widget class="QToolButton" name="buttonBegin">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Scroll to the beginning</p></body></html></string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>Clicking this button navigates to the beginning in the table view above.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>|<</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/resultset_first.png</normaloff>:/icons/resultset_first.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="buttonPrevious">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Scroll one page upwards</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>Clicking this button navigates one page of records upwards in the table view above.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string><</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/resultset_previous.png</normaloff>:/icons/resultset_previous.png</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLabel" name="labelRecordset">
|
||||
<property name="text">
|
||||
<string>0 - 0 of 0</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="buttonNext">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Scroll one page downwards</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>Clicking this button navigates one page of records downwards in the table view above.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>></string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/run</normaloff>:/icons/run</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QToolButton" name="buttonEnd">
|
||||
<property name="enabled">
|
||||
<bool>false</bool>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Scroll to the end</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;Clicking this button navigates up to the end in the table view above.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>>|</string>
|
||||
</property>
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/run_line</normaloff>:/icons/run_line</iconset>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<spacer name="horizontalSpacer_2">
|
||||
<property name="orientation">
|
||||
<enum>Qt::Horizontal</enum>
|
||||
</property>
|
||||
<property name="sizeHint" stdset="0">
|
||||
<size>
|
||||
<width>40</width>
|
||||
<height>20</height>
|
||||
</size>
|
||||
</property>
|
||||
</spacer>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QPushButton" name="buttonGoto">
|
||||
<property name="toolTip">
|
||||
<string><html><head/><body><p>Click here to jump to the specified record</p></body></html></string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>This button is used to navigate to the record number specified in the Go to area.</p></body></html></string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Go to:</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="QLineEdit" name="editGoto">
|
||||
<property name="toolTip">
|
||||
<string>Enter record number to browse</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>Type a record number in this area and click the Go to: button to display the record in the database view</string>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>1</string>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
</layout>
|
||||
<action name="actionShowRowidColumn">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Show rowid column</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Toggle the visibility of the rowid column</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionUnlockViewEditing">
|
||||
<property name="checkable">
|
||||
<bool>true</bool>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Unlock view editing</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>This unlocks the current view for editing. However, you will need appropriate triggers for editing.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionBrowseTableEditDisplayFormat">
|
||||
<property name="text">
|
||||
<string>Edit display format</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Edit the display format of the data in this column</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionNewRecord">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/add_record</normaloff>:/icons/add_record</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>New Record</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Insert a new record in the current table</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Insert a new record in the current table</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>This button creates a new record in the database. Hold the mouse button to open a pop-up menu of different options:</p><ul><li><span style=" font-weight:600;">New Record</span>: insert a new record with default values in the database.</li><li><span style=" font-weight:600;">Insert Values...</span>: open a dialog for entering values before they are inserted in the database. This allows to enter values acomplishing the different constraints. This dialog is also open if the <span style=" font-weight:600;">New Record</span> option fails due to these constraints.</li></ul></body></html></string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionDeleteRecord">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/delete_record</normaloff>:/icons/delete_record</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Delete Record</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Delete the current record</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>This button deletes the record or records currently selected in the table</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This button deletes the record or records currently selected in the table</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="newRecordAction">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/add_record</normaloff>:/icons/add_record</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>New Record</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Insert new record using default values in browsed table</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Insert new record using default values in browsed table</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="insertValuesAction">
|
||||
<property name="text">
|
||||
<string>Insert Values...</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Open a dialog for inserting values in a new record</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Open a dialog for inserting values in a new record</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionFilteredTableExportCsv">
|
||||
<property name="text">
|
||||
<string>Export to &CSV</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Export the filtered data to CSV</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Export the filtered data to CSV</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This button exports the data of the browsed table as currently displayed (after filters, display formats and order column) as a CSV file.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionFilterSaveAsView">
|
||||
<property name="text">
|
||||
<string>Save as &view</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Save the current filter, sort column and display formats as a view</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Save the current filter, sort column and display formats as a view</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This button saves the current setting of the browsed table (filters, display formats and order column) as an SQL view that you can later browse or use in SQL statements.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionSaveFilterAsPopup">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/save_table</normaloff>:/icons/save_table</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Save Table As...</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Save the table as currently displayed</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>Save the table as currently displayed</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string><html><head/><body><p>This popup menu provides the following options applying to the currently browsed and filtered table:</p><ul style="margin-top: 0px; margin-bottom: 0px; margin-left: 0px; margin-right: 0px; -qt-list-indent: 1;"><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Export to CSV: this option exports the data of the browsed table as currently displayed (after filters, display formats and order column) to a CSV file.</li><li style=" margin-top:12px; margin-bottom:12px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;">Save as view: this option saves the current setting of the browsed table (filters, display formats and order column) as an SQL view that you can later browse or use in SQL statements.</li></ul></body></html></string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionHideColumns">
|
||||
<property name="text">
|
||||
<string>Hide column(s)</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Hide selected column(s)</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionShowAllColumns">
|
||||
<property name="text">
|
||||
<string>Show all columns</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Show all columns that were hidden</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionSetTableEncoding">
|
||||
<property name="text">
|
||||
<string>Set encoding</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Change the encoding of the text in the table cells</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionSetAllTablesEncoding">
|
||||
<property name="text">
|
||||
<string>Set encoding for all tables</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Change the default encoding assumed for all tables in the database</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionClearFilters">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/clear_filters</normaloff>:/icons/clear_filters</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Clear Filters</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Clear all filters</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>This button clears all the filters set in the header input fields for the currently browsed table.</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This button clears all the filters set in the header input fields for the currently browsed table.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionClearSorting">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/clear_sorting</normaloff>:/icons/clear_sorting</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Clear Sorting</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Reset the order of rows to the default</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>This button clears the sorting columns specified for the currently browsed table and returns to the default order.</string>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>This button clears the sorting columns specified for the currently browsed table and returns to the default order.</string>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionPrintTable">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/print</normaloff>:/icons/print</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Print</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Print currently browsed table data</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string/>
|
||||
</property>
|
||||
<property name="whatsThis">
|
||||
<string>Print currently browsed table data. Print selection if more than one cell is selected.</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string>Ctrl+P</string>
|
||||
</property>
|
||||
<property name="shortcutContext">
|
||||
<enum>Qt::WidgetShortcut</enum>
|
||||
</property>
|
||||
</action>
|
||||
<action name="actionRefresh">
|
||||
<property name="icon">
|
||||
<iconset resource="icons/icons.qrc">
|
||||
<normaloff>:/icons/refresh</normaloff>:/icons/refresh</iconset>
|
||||
</property>
|
||||
<property name="text">
|
||||
<string>Refresh</string>
|
||||
</property>
|
||||
<property name="toolTip">
|
||||
<string>Refresh the data in the selected table</string>
|
||||
</property>
|
||||
<property name="statusTip">
|
||||
<string>This button refreshes the data in the currently selected table.</string>
|
||||
</property>
|
||||
<property name="shortcut">
|
||||
<string>F5</string>
|
||||
</property>
|
||||
<property name="shortcutContext">
|
||||
<enum>Qt::WidgetShortcut</enum>
|
||||
</property>
|
||||
</action>
|
||||
</widget>
|
||||
<customwidgets>
|
||||
<customwidget>
|
||||
<class>ExtendedTableWidget</class>
|
||||
<extends>QTableWidget</extends>
|
||||
<header>ExtendedTableWidget.h</header>
|
||||
<slots>
|
||||
<signal>foreignKeyClicked(QString,QString,QByteArray)</signal>
|
||||
<signal>foreignKeyClicked(sqlb::ObjectIdentifier,QString,QByteArray)</signal>
|
||||
</slots>
|
||||
</customwidget>
|
||||
</customwidgets>
|
||||
<tabstops>
|
||||
<tabstop>comboBrowseTable</tabstop>
|
||||
<tabstop>dataTable</tabstop>
|
||||
<tabstop>buttonBegin</tabstop>
|
||||
<tabstop>buttonPrevious</tabstop>
|
||||
<tabstop>buttonNext</tabstop>
|
||||
<tabstop>buttonEnd</tabstop>
|
||||
<tabstop>buttonGoto</tabstop>
|
||||
<tabstop>editGoto</tabstop>
|
||||
</tabstops>
|
||||
<resources>
|
||||
<include location="icons/icons.qrc"/>
|
||||
</resources>
|
||||
<connections>
|
||||
<connection>
|
||||
<sender>comboBrowseTable</sender>
|
||||
<signal>activated(QString)</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>updateTable()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>118</x>
|
||||
<y>141</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonPrevious</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigatePrevious()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>86</x>
|
||||
<y>539</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonNext</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigateNext()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>183</x>
|
||||
<y>539</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonGoto</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigateGoto()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>365</x>
|
||||
<y>539</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>editGoto</sender>
|
||||
<signal>returnPressed()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigateGoto()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>506</x>
|
||||
<y>538</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonEnd</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigateEnd()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>223</x>
|
||||
<y>539</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>499</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>buttonBegin</sender>
|
||||
<signal>clicked()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>navigateBegin()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>50</x>
|
||||
<y>539</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>499</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>dataTable</sender>
|
||||
<signal>foreignKeyClicked(sqlb::ObjectIdentifier,QString,QByteArray)</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>jumpToRow(sqlb::ObjectIdentifier,QString,QByteArray)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>70</x>
|
||||
<y>242</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionShowRowidColumn</sender>
|
||||
<signal>triggered(bool)</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>showRowidColumn(bool)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionUnlockViewEditing</sender>
|
||||
<signal>toggled(bool)</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>unlockViewEditing(bool)</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionBrowseTableEditDisplayFormat</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>editDataColumnDisplayFormat()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionNewRecord</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>addRecord()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionDeleteRecord</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>deleteRecord()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>399</x>
|
||||
<y>299</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>newRecordAction</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>addRecord()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>insertValuesAction</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>insertValues()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>20</x>
|
||||
<y>20</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionFilteredTableExportCsv</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>exportFilteredTable()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionFilterSaveAsView</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>saveFilterAsView()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionSetTableEncoding</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>browseDataSetTableEncoding()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionSetAllTablesEncoding</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>browseDataSetDefaultTableEncoding()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionHideColumns</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>hideColumns()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionRefresh</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>TableBrowser</receiver>
|
||||
<slot>updateTable()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>518</x>
|
||||
<y>314</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
<connection>
|
||||
<sender>actionPrintTable</sender>
|
||||
<signal>triggered()</signal>
|
||||
<receiver>dataTable</receiver>
|
||||
<slot>openPrintDialog()</slot>
|
||||
<hints>
|
||||
<hint type="sourcelabel">
|
||||
<x>-1</x>
|
||||
<y>-1</y>
|
||||
</hint>
|
||||
<hint type="destinationlabel">
|
||||
<x>326</x>
|
||||
<y>347</y>
|
||||
</hint>
|
||||
</hints>
|
||||
</connection>
|
||||
</connections>
|
||||
<slots>
|
||||
<slot>updateTable()</slot>
|
||||
<slot>selectionChanged(QModelIndex)</slot>
|
||||
<slot>navigatePrevious()</slot>
|
||||
<slot>navigateNext()</slot>
|
||||
<slot>navigateBegin()</slot>
|
||||
<slot>navigateEnd()</slot>
|
||||
<slot>navigateGoto()</slot>
|
||||
<slot>jumpToRow(sqlb::ObjectIdentifier,QString,QByteArray)</slot>
|
||||
<slot>showRowidColumn(bool)</slot>
|
||||
<slot>unlockViewEditing(bool)</slot>
|
||||
<slot>editDataColumnDisplayFormat()</slot>
|
||||
<slot>addRecord()</slot>
|
||||
<slot>deleteRecord()</slot>
|
||||
<slot>insertValues()</slot>
|
||||
<slot>exportFilteredTable</slot>
|
||||
<slot>saveFilterAsView</slot>
|
||||
<slot>browseDataSetDefaultTableEncoding()</slot>
|
||||
<slot>hideColumns()</slot>
|
||||
<slot>browseDataSetTableEncoding()</slot>
|
||||
</slots>
|
||||
</ui>
|
||||
@@ -77,7 +77,8 @@ HEADERS += \
|
||||
sql/ObjectIdentifier.h \
|
||||
ProxyDialog.h \
|
||||
IconCache.h \
|
||||
SelectItemsPopup.h
|
||||
SelectItemsPopup.h \
|
||||
TableBrowser.h
|
||||
|
||||
SOURCES += \
|
||||
sqlitedb.cpp \
|
||||
@@ -131,7 +132,8 @@ SOURCES += \
|
||||
sql/ObjectIdentifier.cpp \
|
||||
ProxyDialog.cpp \
|
||||
IconCache.cpp \
|
||||
SelectItemsPopup.cpp
|
||||
SelectItemsPopup.cpp \
|
||||
TableBrowser.cpp
|
||||
|
||||
RESOURCES += icons/icons.qrc \
|
||||
translations/flags/flags.qrc \
|
||||
@@ -161,7 +163,8 @@ FORMS += \
|
||||
FileExtensionManager.ui \
|
||||
CondFormatManager.ui \
|
||||
ProxyDialog.ui \
|
||||
SelectItemsPopup.ui
|
||||
SelectItemsPopup.ui \
|
||||
TableBrowser.ui
|
||||
|
||||
TRANSLATIONS += \
|
||||
translations/sqlb_ar_SA.ts \
|
||||
|
||||
Reference in New Issue
Block a user