is now QLabel; shall I really spend my time on this tosh instead of solving real functional problems?; refs #129
This commit is contained in:
@@ -158,11 +158,8 @@ class Browser: public QMainWindow, protected Ui::Browser {
|
|||||||
assert(connect(_editbookmarks.get(), SIGNAL(accepted()),
|
assert(connect(_editbookmarks.get(), SIGNAL(accepted()),
|
||||||
SLOT(saveBookmarks())));
|
SLOT(saveBookmarks())));
|
||||||
} else {
|
} else {
|
||||||
QLineEdit* label(new QLineEdit(_toolbar));
|
QLabel* label(new QLabel(_toolbar));
|
||||||
_url = label;
|
_url = label;
|
||||||
label->setReadOnly(true);
|
|
||||||
// _url->setSizePolicy(QSizePolicy(QSizePolicy::Expanding,
|
|
||||||
// QSizePolicy::Minimum));
|
|
||||||
_toolbar->addWidget(_url);
|
_toolbar->addWidget(_url);
|
||||||
}
|
}
|
||||||
if (!_kiosk) {
|
if (!_kiosk) {
|
||||||
@@ -289,7 +286,7 @@ class Browser: public QMainWindow, protected Ui::Browser {
|
|||||||
if (qobject_cast<QComboBox*>(_url))
|
if (qobject_cast<QComboBox*>(_url))
|
||||||
load(qobject_cast<QComboBox*>(_url)->currentText());
|
load(qobject_cast<QComboBox*>(_url)->currentText());
|
||||||
else
|
else
|
||||||
load(qobject_cast<QLineEdit*>(_url)->text());
|
load(qobject_cast<QLabel*>(_url)->text());
|
||||||
}
|
}
|
||||||
|
|
||||||
void load(QString page) {
|
void load(QString page) {
|
||||||
@@ -649,10 +646,9 @@ class Browser: public QMainWindow, protected Ui::Browser {
|
|||||||
->url().toString());
|
->url().toString());
|
||||||
qobject_cast<QComboBox*>(_url)->lineEdit()->setCursorPosition(0);
|
qobject_cast<QComboBox*>(_url)->lineEdit()->setCursorPosition(0);
|
||||||
} else {
|
} else {
|
||||||
qobject_cast<QLineEdit*>(_url)->setText
|
qobject_cast<QLabel*>(_url)->setText
|
||||||
(qobject_cast<QWebView*>(_tabs->currentWidget())
|
(qobject_cast<QWebView*>(_tabs->currentWidget())
|
||||||
->url().toString());
|
->url().toString());
|
||||||
qobject_cast<QLineEdit*>(_url)->setCursorPosition(0);
|
|
||||||
}
|
}
|
||||||
activateTab();
|
activateTab();
|
||||||
}
|
}
|
||||||
@@ -932,8 +928,7 @@ class Browser: public QMainWindow, protected Ui::Browser {
|
|||||||
qobject_cast<QComboBox*>(_url)->setEditText(url.toString());
|
qobject_cast<QComboBox*>(_url)->setEditText(url.toString());
|
||||||
qobject_cast<QComboBox*>(_url)->lineEdit()->setCursorPosition(0);
|
qobject_cast<QComboBox*>(_url)->lineEdit()->setCursorPosition(0);
|
||||||
} else {
|
} else {
|
||||||
qobject_cast<QLineEdit*>(_url)->setText(url.toString());
|
qobject_cast<QLabel*>(_url)->setText(url.toString());
|
||||||
qobject_cast<QLineEdit*>(_url)->setCursorPosition(0);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1508,7 +1503,7 @@ class Browser: public QMainWindow, protected Ui::Browser {
|
|||||||
(qobject_cast<QComboBox*>(_url)->lineEdit())
|
(qobject_cast<QComboBox*>(_url)->lineEdit())
|
||||||
->changeStyleSheet(tr("background-color: white", "valid url"));
|
->changeStyleSheet(tr("background-color: white", "valid url"));
|
||||||
else
|
else
|
||||||
qobject_cast<QLineEdit*>(_url)
|
qobject_cast<QLabel*>(_url)
|
||||||
->setStyleSheet(tr("background-color: white", "valid url"));
|
->setStyleSheet(tr("background-color: white", "valid url"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user