Esempio n. 1
0
BitcoinGUI::~BitcoinGUI()
{
    saveWindowGeometry();
    if(trayIcon) // Hide tray icon, as deleting will let it linger until quit (on Ubuntu)
        trayIcon->hide();
#ifdef Q_OS_MAC
    delete appMenuBar;
    MacDockIconHandler::instance()->setMainWindow(NULL);
#endif
}
Esempio n. 2
0
void Widget::closeEvent(QCloseEvent *event)
{
    if (Settings::getInstance().getShowSystemTray() && Settings::getInstance().getCloseToTray() == true)
    {
        event->ignore();
        this->hide();
    }
    else
    {
        saveWindowGeometry();
        saveSplitterGeometry();
        qApp->exit(0);
        QWidget::closeEvent(event);
    }
}
Esempio n. 3
0
void FMCConsole::setupDefaultConfig()
{
    MYASSERT(m_main_config != 0);

    saveWindowGeometry();

#if VASFMC_GAUGE
    m_main_config->setValue(CFG_VASFMC_DIR, VasPath::getPath());
#else
    m_main_config->setValue(CFG_VASFMC_DIR, QDir::current().absolutePath());
#endif

    m_main_config->setValue(CFG_STYLE, CFG_STYLE_A);
    m_main_config->setValue(CFG_CONSOLE_MAX_LOGLINES, "500");
    m_main_config->setValue(CFG_PERSISTANCE_FILE, "persistence.dat");
    m_main_config->setValue(CFG_ENABLE_CONFIG_ACCESS, 0);
    m_main_config->setValue(CFG_BEST_ANTI_ALIASING, 1);
    m_main_config->setValue(CFG_FONT_NAME, "fmc.fnt");
    m_main_config->setValue(CFG_ACTIVE_FONT_SIZE, 15);
    m_main_config->setValue(CFG_ACTIVE_FONT_INDEX, 4);
    m_main_config->setValue(CFG_FONT_SIZE1, 12);
    m_main_config->setValue(CFG_FONT_SIZE2, 13);
    m_main_config->setValue(CFG_FONT_SIZE3, 14);
    m_main_config->setValue(CFG_FONT_SIZE4, 15);
    m_main_config->setValue(CFG_FONT_SIZE5, 16);
    m_main_config->setValue(CFG_FONT_SIZE6, 18);
    m_main_config->setValue(CFG_FONT_SIZE7, 20);
    m_main_config->setValue(CFG_FONT_SIZE8, 24);
    m_main_config->setValue(CFG_FONT_SIZE9, 32);
    m_main_config->setValue(CFG_ASK_FOR_QUIT, 0);
    m_main_config->setValue(CFG_FLIGHTPLAN_SUBDIR, "fps");
    m_main_config->setValue(CFG_AIRCRAFT_DATA_SUBDIR, "aircraft_data");
    m_main_config->setValue(CFG_CHECKLIST_SUBDIR, "checklists");
    m_main_config->setValue(CFG_GEODATA_FILE, "gshhs/gshhs_l.b");
    m_main_config->setValue(CFG_GEODATA_FILTER_LEVEL, 1);
    m_main_config->setValue(CFG_DECLINATION_DATAFILE, "WMM2005.cof");
    m_main_config->setValue(CFG_FLIGHTSTATUS_SMOOTHING_DELAY_MS, 150);
//Make sure, that only in WIN32-Environments the default FS_ACCESS_TYPE is MSFS
#ifdef Q_OS_WIN32
    m_main_config->setValue(CFG_FS_ACCESS_TYPE, FS_ACCESS_TYPE_MSFS);
#else
    m_main_config->setValue(CFG_FS_ACCESS_TYPE, FS_ACCESS_TYPE_XPLANE);
#endif
}
Esempio n. 4
0
FMCConsole::~FMCConsole()
{
    for(int index=0; index < m_time_used_list.count(); ++index) Logger::log(m_time_used_list[index]);

    delete m_navdisplay_left_handler;
    delete m_upper_ecam_handler;
    delete m_pfd_left_handler;
    delete m_cdu_left_handler;
    delete m_cdu_right_handler;
    delete m_fmc_control;
    delete m_fcu_handler;
    delete m_gps_handler;
    delete m_navdisplay_right_handler;
    delete m_pfd_right_handler;
    delete m_fmc_sounds_handler;

#ifdef USE_OPENAL
    AlContext::destroyContext();
#endif

    saveWindowGeometry();
    m_main_config->saveToFile();
    delete m_main_config;
}
Esempio n. 5
0
SyntaxEditorWindow::~SyntaxEditorWindow()
{
 	saveWindowGeometry(this, "Look", "SyntaxEditorGeometry");
}
GaduUnregisterAccountWindow::~GaduUnregisterAccountWindow()
{
	saveWindowGeometry(this, "General", "GaduUnregisterAccountGeometry");
}