]> cygwin.com Git - cygwin-apps/setup.git/blame - splash.cc
Added dpiAwareness element to manifest
[cygwin-apps/setup.git] / splash.cc
CommitLineData
46187c8f 1/*
25130a4d 2 * Copyright (c) 2001, 2002, 2003 Gary R. Van Sickle.
46187c8f
DD
3 *
4 * This program is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
8 *
9 * A copy of the GNU General Public License can be found at
10 * http://www.gnu.org/
11 *
ab57ceaa 12 * Written by Gary R. Van Sickle <g.r.vansickle@worldnet.att.net>
46187c8f
DD
13 *
14 */
15
2b734ec7
MB
16/* This is the implementation of the SplashPage class. Since the splash page
17 * has little to do, there's not much here. */
46187c8f 18
2b734ec7 19#include "setup_version.h"
ab57ceaa 20#include "resource.h"
ab57ceaa 21#include "splash.h"
46187c8f 22
01878bdf 23#define SPLASH_URL "https://cygwin.com"
f97b5c11 24#define SPLASH_COPYRIGHT L"Copyright © 2000-2024"
af6bf695 25#define SPLASH_TRANSLATE_URL "https://cygwin.com/setup/translate"
01878bdf 26
daab12c7
BD
27static ControlAdjuster::ControlInfo SplashControlsInfo[] = {
28 { IDC_SPLASH_TEXT, CP_STRETCH, CP_STRETCH },
8cbcc851 29 { IDC_SPLASH_ICON, CP_LEFT, CP_TOP },
daab12c7
BD
30 { IDC_VERSION, CP_LEFT, CP_BOTTOM },
31 { IDC_SPLASH_COPYR, CP_LEFT, CP_BOTTOM },
32 { IDC_SPLASH_URL, CP_LEFT, CP_BOTTOM },
af6bf695 33 { IDC_SPLASH_TRANSLATE, CP_LEFT, CP_BOTTOM },
daab12c7
BD
34 {0, CP_LEFT, CP_TOP}
35};
36
37SplashPage::SplashPage ()
38{
39 sizeProcessor.AddControlInfo (SplashControlsInfo);
40}
41
ab57ceaa
RC
42bool
43SplashPage::Create ()
46187c8f 44{
ab57ceaa 45 return PropertyPage::Create (IDD_SPLASH);
46187c8f
DD
46}
47
ab57ceaa
RC
48void
49SplashPage::OnInit ()
46187c8f 50{
fd571d50
JT
51 std::string ver;
52 if (setup_version[0])
53 {
54 ver = setup_version;
55 ver += " (" + machine_name(WindowsProcessMachine()) + ")";
56 }
57
d2a3615c 58 ::SetWindowText (GetDlgItem (IDC_VERSION), ver.c_str());
f97b5c11 59 ::SetWindowTextW (GetDlgItem (IDC_SPLASH_COPYR), SPLASH_COPYRIGHT);
01878bdf
JT
60 ::SetWindowText (GetDlgItem (IDC_SPLASH_URL), SPLASH_URL);
61 makeClickable (IDC_SPLASH_URL, SPLASH_URL);
af6bf695 62 makeClickable (IDC_SPLASH_TRANSLATE, SPLASH_TRANSLATE_URL);
46187c8f 63}
This page took 0.241516 seconds and 6 git commands to generate.