mirror of
https://github.com/Ximi1970/systray-x.git
synced 2026-01-31 03:19:03 +01:00
Fix visibility option
This commit is contained in:
@@ -85,6 +85,8 @@ Preferences::Preferences( QObject *parent ) : QObject( parent )
|
||||
m_version_hash = QLatin1String( APP_GITHASH );
|
||||
m_version_branch = QLatin1String( APP_GITBRANCH );
|
||||
|
||||
m_browser_version = "0.0.0";
|
||||
|
||||
m_start_app = "";
|
||||
m_start_app_args = "";
|
||||
m_close_app = "";
|
||||
|
||||
@@ -115,15 +115,6 @@ PreferencesDialog::PreferencesDialog( SysTrayXLink *link, Preferences *pref, QWi
|
||||
m_ui->newIndicatorTypeGroup->setId( m_ui->newIconStarRadioButton, Preferences::PREF_NEW_INDICATOR_STAR );
|
||||
m_ui->newIndicatorTypeGroup->setId( m_ui->newShadeRadioButton, Preferences::PREF_NEW_INDICATOR_SHADE);
|
||||
|
||||
if( m_pref->getBrowserVersion().split(".")[0].toInt() < 115 )
|
||||
{
|
||||
m_ui->specialOptionsGroupBox->setVisible( false );
|
||||
}
|
||||
else
|
||||
{
|
||||
setApiCountMethod( m_pref->getApiCountMethod() );
|
||||
}
|
||||
|
||||
/*
|
||||
* Signals and slots
|
||||
*/
|
||||
@@ -154,6 +145,11 @@ PreferencesDialog::PreferencesDialog( SysTrayXLink *link, Preferences *pref, QWi
|
||||
*/
|
||||
setStartupDelay( m_pref->getStartupDelay() );
|
||||
|
||||
/*
|
||||
* Set API count method
|
||||
*/
|
||||
setApiCountMethod( m_pref->getApiCountMethod() );
|
||||
|
||||
/*
|
||||
* Set number alignment
|
||||
*/
|
||||
@@ -542,6 +538,16 @@ void PreferencesDialog::setApiCountMethod( bool state )
|
||||
*/
|
||||
void PreferencesDialog::slotShowDialog()
|
||||
{
|
||||
QString version = m_pref->getBrowserVersion().split(".")[0];
|
||||
if( version.toInt() < 115 )
|
||||
{
|
||||
m_ui->specialOptionsGroupBox->setVisible( false );
|
||||
}
|
||||
else
|
||||
{
|
||||
m_ui->specialOptionsGroupBox->setVisible( true );
|
||||
}
|
||||
|
||||
showNormal();
|
||||
activateWindow();
|
||||
}
|
||||
|
||||
@@ -206,6 +206,8 @@ SysTrayX::SysTrayX( QObject *parent ) : QObject( parent )
|
||||
getPreferences();
|
||||
|
||||
/*
|
||||
m_preferences->setBrowserVersion( "115.1.0" );
|
||||
// m_preferences->setBrowserVersion( "102.2.3" );
|
||||
slotLoadLanguage( "en-US" );
|
||||
//slotLoadLanguage( "it" );
|
||||
//slotLoadLanguage( "nl" );
|
||||
|
||||
Reference in New Issue
Block a user