mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-01 13:36:48 +08:00
GUI improvements found during #707
* logs only screen in core as default * find top window, only use Qt::WA_TranslucentBackground on top level (Qt 5.6.1) * correct presize when insert * resize ATC when first station is added
This commit is contained in:
@@ -8,10 +8,12 @@
|
||||
*/
|
||||
|
||||
#include "blackgui/enableforframelesswindow.h"
|
||||
#include "blackgui/guiutility.h"
|
||||
#include "blackmisc/icons.h"
|
||||
#include "blackmisc/stringutils.h"
|
||||
#include "blackmisc/worker.h"
|
||||
|
||||
|
||||
#include <QEvent>
|
||||
#include <QFlags>
|
||||
#include <QHBoxLayout>
|
||||
@@ -110,7 +112,12 @@ namespace BlackGui
|
||||
bool frameless = (mode == WindowFrameless);
|
||||
// http://stackoverflow.com/questions/18316710/frameless-and-transparent-window-qt5
|
||||
this->m_widget->setAttribute(Qt::WA_NoSystemBackground, frameless);
|
||||
this->m_widget->setAttribute(Qt::WA_TranslucentBackground, frameless);
|
||||
|
||||
// https://bugreports.qt.io/browse/QTBUG-52206
|
||||
if (CGuiUtility::isTopLevelWidget(this->m_widget))
|
||||
{
|
||||
this->m_widget->setAttribute(Qt::WA_TranslucentBackground, frameless);
|
||||
}
|
||||
|
||||
// Qt::WA_PaintOnScreen leads to a warning
|
||||
// setMask(QRegion(10, 10, 10, 10) would work, but requires "complex" calcs for rounded corners
|
||||
|
||||
Reference in New Issue
Block a user