mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-15 16:11:40 -06:00
4.44 beta
This commit is contained in:
committed by
Kornel Lesiński
parent
804edc5756
commit
d9666cf046
BIN
CPP/7zip/FileManager/Resource/AboutDialog/7zipLogo.ico
Executable file
BIN
CPP/7zip/FileManager/Resource/AboutDialog/7zipLogo.ico
Executable file
Binary file not shown.
|
After Width: | Height: | Size: 8.9 KiB |
60
CPP/7zip/FileManager/Resource/AboutDialog/AboutDialog.cpp
Executable file
60
CPP/7zip/FileManager/Resource/AboutDialog/AboutDialog.cpp
Executable file
@@ -0,0 +1,60 @@
|
||||
// AboutDialog.cpp
|
||||
|
||||
#include "StdAfx.h"
|
||||
|
||||
#include "resource.h"
|
||||
#include "AboutDialog.h"
|
||||
#include "../../HelpUtils.h"
|
||||
#include "../../LangUtils.h"
|
||||
|
||||
static CIDLangPair kIDLangPairs[] =
|
||||
{
|
||||
{ IDC_ABOUT_STATIC_REGISTER_INFO, 0x01000103 },
|
||||
{ IDC_ABOUT_BUTTON_SUPPORT, 0x01000104 },
|
||||
{ IDC_ABOUT_BUTTON_REGISTER, 0x01000105 },
|
||||
{ IDOK, 0x02000702 }
|
||||
};
|
||||
|
||||
#define MY_HOME_PAGE TEXT("http://www.7-zip.org/")
|
||||
|
||||
static LPCTSTR kHomePageURL = MY_HOME_PAGE;
|
||||
static LPCTSTR kRegisterPageURL = MY_HOME_PAGE TEXT("register.html");
|
||||
static LPCTSTR kSupportPageURL = MY_HOME_PAGE TEXT("support.html");
|
||||
|
||||
static LPCWSTR kHelpTopic = L"start.htm";
|
||||
|
||||
bool CAboutDialog::OnInit()
|
||||
{
|
||||
LangSetWindowText(HWND(*this), 0x01000100);
|
||||
LangSetDlgItemsText(HWND(*this), kIDLangPairs, sizeof(kIDLangPairs) / sizeof(kIDLangPairs[0]));
|
||||
return CModalDialog::OnInit();
|
||||
}
|
||||
|
||||
void CAboutDialog::OnHelp()
|
||||
{
|
||||
ShowHelpWindow(NULL, kHelpTopic);
|
||||
}
|
||||
|
||||
static void MyShellExecute(LPCTSTR url)
|
||||
{
|
||||
::ShellExecute(NULL, NULL, url, NULL, NULL, SW_SHOWNORMAL);
|
||||
}
|
||||
|
||||
bool CAboutDialog::OnButtonClicked(int buttonID, HWND buttonHWND)
|
||||
{
|
||||
switch(buttonID)
|
||||
{
|
||||
case IDC_ABOUT_BUTTON_HOMEPAGE:
|
||||
::MyShellExecute(kHomePageURL);
|
||||
break;
|
||||
case IDC_ABOUT_BUTTON_REGISTER:
|
||||
::MyShellExecute(kRegisterPageURL);
|
||||
break;
|
||||
case IDC_ABOUT_BUTTON_SUPPORT:
|
||||
::MyShellExecute(kSupportPageURL);
|
||||
break;
|
||||
default:
|
||||
return CModalDialog::OnButtonClicked(buttonID, buttonHWND);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
18
CPP/7zip/FileManager/Resource/AboutDialog/AboutDialog.h
Executable file
18
CPP/7zip/FileManager/Resource/AboutDialog/AboutDialog.h
Executable file
@@ -0,0 +1,18 @@
|
||||
// AboutDialog.h
|
||||
|
||||
#ifndef __ABOUTDIALOG_H
|
||||
#define __ABOUTDIALOG_H
|
||||
|
||||
#include "resource.h"
|
||||
#include "Windows/Control/Dialog.h"
|
||||
|
||||
class CAboutDialog: public NWindows::NControl::CModalDialog
|
||||
{
|
||||
public:
|
||||
virtual bool OnInit();
|
||||
virtual void OnHelp();
|
||||
virtual bool OnButtonClicked(int buttonID, HWND buttonHWND);
|
||||
INT_PTR Create(HWND wndParent = 0) { return CModalDialog::Create(IDD_ABOUT, wndParent); }
|
||||
};
|
||||
|
||||
#endif
|
||||
16
CPP/7zip/FileManager/Resource/AboutDialog/StdAfx.h
Executable file
16
CPP/7zip/FileManager/Resource/AboutDialog/StdAfx.h
Executable file
@@ -0,0 +1,16 @@
|
||||
// stdafx.h
|
||||
|
||||
#ifndef __STDAFX_H
|
||||
#define __STDAFX_H
|
||||
|
||||
#define _WIN32_WINNT 0x0400
|
||||
|
||||
// it's for Windows NT supporting (MENUITEMINFOW)
|
||||
#define WINVER 0x0400
|
||||
|
||||
#include <windows.h>
|
||||
#include <commctrl.h>
|
||||
|
||||
#include "Common/NewHandler.h"
|
||||
|
||||
#endif
|
||||
6
CPP/7zip/FileManager/Resource/AboutDialog/resource.h
Executable file
6
CPP/7zip/FileManager/Resource/AboutDialog/resource.h
Executable file
@@ -0,0 +1,6 @@
|
||||
#define IDD_ABOUT 100
|
||||
#define IDI_LOGO 138
|
||||
#define IDC_ABOUT_STATIC_REGISTER_INFO 1010
|
||||
#define IDC_ABOUT_BUTTON_HOMEPAGE 1020
|
||||
#define IDC_ABOUT_BUTTON_SUPPORT 1021
|
||||
#define IDC_ABOUT_BUTTON_REGISTER 1022
|
||||
41
CPP/7zip/FileManager/Resource/AboutDialog/resource.rc
Executable file
41
CPP/7zip/FileManager/Resource/AboutDialog/resource.rc
Executable file
@@ -0,0 +1,41 @@
|
||||
#include "resource.h"
|
||||
#include "../../../GuiCommon.rc"
|
||||
#include "../../../MyVersion.h"
|
||||
|
||||
#define xSize2 224
|
||||
#define ySize2 158
|
||||
#define xSize (xSize2 + marg + marg)
|
||||
#define ySize (ySize2 + marg + marg)
|
||||
|
||||
#define bXPos (xSize - marg - bXSize)
|
||||
#define bYPos (ySize - marg - bYSize)
|
||||
|
||||
#undef b2XSize
|
||||
#undef b2XPos
|
||||
#undef infoYPos
|
||||
#undef infoYSize
|
||||
|
||||
#define b2XSize 94
|
||||
#define b2XPos (xSize - marg - b2XSize)
|
||||
#define gSpace 2
|
||||
#define gSize (xSize2 - gSpace - b2XSize)
|
||||
|
||||
#define infoYPos 91
|
||||
#define infoYSize (ySize2 - infoYPos - bYSize - 2)
|
||||
|
||||
IDI_LOGO ICON "7zipLogo.ico"
|
||||
|
||||
IDD_ABOUT DIALOG 0, 0, xSize, ySize MY_MODAL_DIALOG_STYLE
|
||||
CAPTION "About 7-Zip"
|
||||
MY_FONT
|
||||
BEGIN
|
||||
PUSHBUTTON "OK", IDOK, bXPos, bYPos, bXSize, bYSize
|
||||
PUSHBUTTON "www.7-zip.org", IDC_ABOUT_BUTTON_HOMEPAGE, b2XPos, 7, b2XSize, bYSize
|
||||
PUSHBUTTON "Support", IDC_ABOUT_BUTTON_SUPPORT, b2XPos, 30, b2XSize, bYSize
|
||||
PUSHBUTTON "Register", IDC_ABOUT_BUTTON_REGISTER, b2XPos, 53, b2XSize, bYSize
|
||||
ICON IDI_LOGO, -1, marg, marg, 20, 20, SS_REALSIZEIMAGE
|
||||
LTEXT MY_7ZIP_VERSION, -1, marg, 54, gSize, 9
|
||||
LTEXT MY_COPYRIGHT, -1, marg, 67, gSize, 17
|
||||
LTEXT "7-Zip is free software. However, you can support development of 7-Zip by registering.",
|
||||
IDC_ABOUT_STATIC_REGISTER_INFO, marg, infoYPos, xSize2, infoYSize
|
||||
END
|
||||
Reference in New Issue
Block a user