LRESULT CWizardInterfacePage::OnWizardNext()
{
	UpdateData( TRUE );

	Settings.Downloads.SimpleBar = m_bSimpleDownloadBars != FALSE;

	if ( m_bExpert && Settings.General.GUIMode == GUI_BASIC )
	{
		CWaitCursor pCursor;
		CMainWnd* pMainWnd = (CMainWnd*)AfxGetMainWnd();

		Settings.General.GUIMode = GUI_TABBED;
		Settings.Skin.RowSize = 17;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}
	else if ( ! m_bExpert && Settings.General.GUIMode != GUI_BASIC )
	{
		CWaitCursor pCursor;
		CMainWnd* pMainWnd = (CMainWnd*)AfxGetMainWnd();

		Settings.General.GUIMode = GUI_BASIC;
		Settings.Skin.RowSize = 18;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}

	Settings.Save();

	return 0;
}
示例#2
0
BOOL CWizardSheet::RunWizard(CWnd* pParent)
{
	BOOL bSuccess = FALSE;

	CWizardSheet pSheet( pParent );

	CWizardWelcomePage		pWelcome;
	CWizardConnectionPage	pConnection;
	CWizardSharePage		pShare;
	CWizardProfilePage		pProfile;
	CWizardInterfacePage	pInterface;
	CWizardNetworksPage		pNetworks;
	CWizardFinishedPage		pFinished;

	pSheet.AddPage( &pWelcome );
	pSheet.AddPage( &pConnection );
	pSheet.AddPage( &pShare );
	pSheet.AddPage( &pProfile );
	pSheet.AddPage( &pInterface );
	pSheet.AddPage( &pNetworks );
	pSheet.AddPage( &pFinished );

	bSuccess = ( pSheet.DoModal() == IDOK );

	CWaitCursor pCursor;
	CMainWnd* pMainWnd = (CMainWnd*)AfxGetMainWnd();

	if ( pInterface.m_bExpert && Settings.General.GUIMode == GUI_BASIC )
	{
		Settings.General.GUIMode = GUI_TABBED;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}
	else if ( ! pInterface.m_bExpert && Settings.General.GUIMode != GUI_BASIC )
	{
		Settings.General.GUIMode = GUI_BASIC;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}

	Settings.Save();

	return bSuccess;
}
示例#3
0
LRESULT CWizardInterfacePage::OnWizardNext()
{
	UpdateData( TRUE );

	Settings.Downloads.SimpleBar = m_bSimpleDownloadBars != FALSE;

	if ( ! m_bBasic && Settings.General.GUIMode == GUI_BASIC )
	{
		CWaitCursor pCursor;
		CMainWnd* pMainWnd = (CMainWnd*)AfxGetMainWnd();

		Settings.Skin.RowSize = 17;
		Settings.General.GUIMode = GUI_TABBED;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}
	else if ( m_bBasic && Settings.General.GUIMode != GUI_BASIC )
	{
		CWaitCursor pCursor;
		CMainWnd* pMainWnd = (CMainWnd*)AfxGetMainWnd();

		Settings.Skin.RowSize = 18;
		Settings.General.GUIMode = GUI_BASIC;
		pMainWnd->SetGUIMode( Settings.General.GUIMode, FALSE );
	}

	Settings.Save();

	if ( m_nSkin )
	{
		CWaitCursor pCursor;

		ClearSkins();

		if ( m_nSkin == 2 && theApp.m_nWinVer >= WIN_10)	// Dark Mode
		{
			theApp.WriteProfileInt( L"Skins", L"Windows 10\\Windows10.Dark.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows 10\\Windows10.DarkFrames.xml", 1 );
		}
		else if ( m_nSkin == 2)	// Dark Skin
		{
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinDark.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\Skin8AltFrames.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVistaRemote.xml", 1 );
		}
		else if ( theApp.m_nWinVer >= WIN_10 )
		{
			theApp.WriteProfileInt( L"Skins", L"Windows 10\\Windows10.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows 10\\Windows10.Frames.xml", 1 );
		}
		else if ( theApp.m_nWinVer >= WIN_8 )
		{
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\Skin8.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\Skin8Frames.xml", 1 );
		}
		else if ( theApp.m_nWinVer >= WIN_7 )
		{
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\Skin7.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVistaFrames.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVistaRemote.xml", 1 );
		}
		else if ( theApp.m_nWinVer < WIN_7 )
		{
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVista.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVistaFrames.xml", 1 );
			theApp.WriteProfileInt( L"Skins", L"Windows Collection\\SkinVistaRemote.xml", 1 );
		}

		if ( theApp.m_nWinVer >= WIN_7 && GetSystemMetrics( SM_CYSCREEN ) > 1050 )	// ToDo: Detect DPI
			theApp.WriteProfileInt( L"Skins", L"Flags\\Flags.xml", 1 );

		PostMainWndMessage( WM_SKINCHANGED );
		Sleep( 2500 );		// Wait a few seconds
		GetParent()->Invalidate();
	}

	return 0;
}