mirror of
https://gitee.com/vnotex/vnote.git
synced 2025-07-05 05:49:53 +08:00
add notices for fresh windows users
This commit is contained in:
parent
d9b92c89c2
commit
58643ab7f2
@ -1696,6 +1696,7 @@ void VConfigManager::checkVersion()
|
||||
const QString key("version");
|
||||
QString ver = getConfigFromSettings("global", key).toString();
|
||||
m_versionChanged = ver != c_version;
|
||||
m_freshInstall = ver.isEmpty();
|
||||
if (m_versionChanged) {
|
||||
setConfigToSettings("global", key, c_version);
|
||||
}
|
||||
|
@ -603,6 +603,7 @@ public:
|
||||
bool getParsePasteLocalImage() const;
|
||||
|
||||
bool versionChanged() const;
|
||||
bool isFreshInstall() const;
|
||||
|
||||
const QColor &getBaseBackground() const;
|
||||
void setBaseBackground(const QColor &p_bg);
|
||||
@ -1110,6 +1111,9 @@ private:
|
||||
// Whether the VNote instance has different version of vnote.ini.
|
||||
bool m_versionChanged;
|
||||
|
||||
// Whether VNote is first installed on this machine.
|
||||
bool m_freshInstall;
|
||||
|
||||
// Base background of MainWindow.
|
||||
QColor m_baseBackground;
|
||||
|
||||
@ -2825,6 +2829,11 @@ inline bool VConfigManager::versionChanged() const
|
||||
return m_versionChanged;
|
||||
}
|
||||
|
||||
inline bool VConfigManager::isFreshInstall() const
|
||||
{
|
||||
return m_freshInstall;
|
||||
}
|
||||
|
||||
inline const QColor &VConfigManager::getBaseBackground() const
|
||||
{
|
||||
return m_baseBackground;
|
||||
|
@ -3478,6 +3478,24 @@ void VMainWindow::kickOffStartUpTimer(const QStringList &p_files)
|
||||
|
||||
m_syncNoteListToCurrentTab = true;
|
||||
|
||||
#if defined(Q_OS_WIN)
|
||||
if (g_config->isFreshInstall()) {
|
||||
VUtils::showMessage(QMessageBox::Information,
|
||||
tr("Notices for Windows Users"),
|
||||
tr("OpenGL requried by VNote may not work well on Windows by default."
|
||||
"You may update your display card driver or set another openGL option in VNote's Settings dialog."
|
||||
"Check <a href=\"https://github.com/tamlok/vnote/issues/853\">GitHub issue</a> for details."),
|
||||
tr("Strange behaviors includes:<br/>"
|
||||
"* Interface freezes and does not response;<br/>"
|
||||
"* Widgets are out of order after maximizing and restoring the main window;<br/>"
|
||||
"* No cursor in edit mode;<br/>"
|
||||
"* Menus are not clickable in full screen mode."),
|
||||
QMessageBox::Ok,
|
||||
QMessageBox::Ok,
|
||||
this);
|
||||
}
|
||||
#endif
|
||||
|
||||
g_config->updateLastStartDateTime();
|
||||
});
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user