mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-14 00:28:42 +00:00
Manage Perspectives - perspectives list cosmetics
- Disable in-place name edition - Use double click to edit perspective To match the behavior of similar lists.
This commit is contained in:
@@ -53,6 +53,7 @@ PerspectiveDialog::PerspectiveDialog(QWidget *parent, AbstractView *tabView) : Q
|
||||
perspectiveTable->setShowGrid(false);
|
||||
perspectiveTable->setSelectionMode(QAbstractItemView::SingleSelection);
|
||||
perspectiveTable->setSelectionBehavior(QAbstractItemView::SelectRows);
|
||||
perspectiveTable->setEditTriggers(QAbstractItemView::NoEditTriggers);
|
||||
perspectiveTable->setAcceptDrops(true);
|
||||
//perspectiveTable->setDropIndicatorShown(true);
|
||||
|
||||
@@ -121,6 +122,7 @@ PerspectiveDialog::PerspectiveDialog(QWidget *parent, AbstractView *tabView) : Q
|
||||
connect(perspectiveTable, SIGNAL(currentItemChanged(QTableWidgetItem*,QTableWidgetItem*)), this, SLOT(perspectiveSelected()));
|
||||
connect(perspectiveTable, SIGNAL(chartMoved(GcChartWindow*)), this, SLOT(perspectiveSelected())); // just reset the chart list
|
||||
connect(perspectiveTable, SIGNAL(itemChanged(QTableWidgetItem*)), this, SLOT(perspectiveNameChanged(QTableWidgetItem*))); // user edit
|
||||
connect(perspectiveTable, SIGNAL(itemDoubleClicked(QTableWidgetItem*)), this, SLOT(editPerspectiveClicked())); // Double click -> edit
|
||||
|
||||
connect(editButton, SIGNAL(clicked(bool)), this, SLOT(editPerspectiveClicked()));
|
||||
connect(importPerspective, SIGNAL(clicked(bool)), this, SLOT(importPerspectiveClicked()));
|
||||
|
||||
@@ -162,7 +162,11 @@ WebPageWindow::WebPageWindow(Context *context) : GcChartWindow(context), context
|
||||
view->settings()->setAttribute(QWebEngineSettings::LocalContentCanAccessRemoteUrls, true);
|
||||
view->settings()->setAttribute(QWebEngineSettings::LocalStorageEnabled, true);
|
||||
|
||||
#if QT_VERSION < 0x060000
|
||||
view->setPage(new simpleWebPage());
|
||||
#else
|
||||
view->setPage(new QWebEnginePage(new QWebEngineProfile("Default")));
|
||||
#endif
|
||||
view->setContentsMargins(0,0,0,0);
|
||||
view->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
view->setAcceptDrops(false);
|
||||
|
||||
Reference in New Issue
Block a user