Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
d2808e6c92 | ||
|
|
6163066b5b | ||
|
|
4b1502df8c | ||
|
|
e9e3bdf59c |
@@ -1,243 +0,0 @@
|
||||
// AppliBase.cpp : <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃G<CC83><47><EFBFBD>g<EFBFBD><67> <20>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>`<60><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "commctrl.h"
|
||||
|
||||
#include "TwrCore.h"
|
||||
#include "AppliBase.h"
|
||||
#include "ModelessDialog.h"
|
||||
#include "BaseForm.h"
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ŗL<C597>̃w<CC83>b<EFBFBD>_<EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43>
|
||||
#include "../MyAppli.h"
|
||||
|
||||
#define MAX_LOADSTRING 100
|
||||
|
||||
// <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD>:
|
||||
TCHAR szTitle[MAX_LOADSTRING]; // <20>^<5E>C<EFBFBD>g<EFBFBD><67> <20>o<EFBFBD>[<5B>̃e<CC83>L<EFBFBD>X<EFBFBD>g
|
||||
TCHAR szWindowClass[MAX_LOADSTRING]; // <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E <20>N<EFBFBD><4E><EFBFBD>X<EFBFBD><58>
|
||||
BaseForm *baseForm;
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ŗL<C597>̃O<CC83><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD>
|
||||
MyAppli *appObj;
|
||||
|
||||
extern void initModelessCallback(void);
|
||||
|
||||
// <20><><EFBFBD>̃R<CC83>[<5B>h <20><><EFBFBD>W<EFBFBD><57><EFBFBD>[<5B><><EFBFBD>Ɋ܂܂<DC82><DC82><EFBFBD><EFBFBD><EFBFBD><D690>̐錾<CC90><E98CBE><EFBFBD>]<5D><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD>:
|
||||
int runApplication(
|
||||
HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow);
|
||||
ATOM MyRegisterClass(HINSTANCE hInstance);
|
||||
BOOL InitInstance(HINSTANCE, int);
|
||||
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
|
||||
INT_PTR CALLBACK About(HWND, UINT, WPARAM, LPARAM);
|
||||
bool handleDialogMessage(LPMSG lpMsg);
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>[<5B>`<60><>
|
||||
*
|
||||
* @param hInstance <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param hPrevInstance <20><><EFBFBD>g<EFBFBD>p
|
||||
* @param lpCmdLine <20>R<EFBFBD>}<7D><><EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43>
|
||||
* @param nCmdShow <20>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
* @return <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>R<EFBFBD>[<5B>h
|
||||
*/
|
||||
int APIENTRY _tWinMain(HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow)
|
||||
{
|
||||
INITCOMMONCONTROLSEX iccx;
|
||||
iccx.dwSize = sizeof(INITCOMMONCONTROLSEX);
|
||||
iccx.dwICC = ICC_TAB_CLASSES;
|
||||
if (!InitCommonControlsEx(&iccx)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
initModelessDialog();
|
||||
initModelessCallback();
|
||||
|
||||
// TODO: <20><><EFBFBD><EFBFBD><EFBFBD>ɃA<C983>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD><4E><EFBFBD>X<EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD><58><EFBFBD>ݒ肵<DD92>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
appObj = new MyAppli();
|
||||
baseForm = appObj->createBaseWindow();
|
||||
|
||||
// <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>\<5C><><EFBFBD>O<EFBFBD>̃A<CC83>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnAppliStart(lpCmdLine);
|
||||
|
||||
int result = runApplication(hInstance, hPrevInstance, lpCmdLine, nCmdShow);
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̌<EFBFBD><CC8C>n<EFBFBD><6E><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnAppliEnd();
|
||||
|
||||
delete baseForm;
|
||||
delete appObj;
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD>n
|
||||
*
|
||||
* @param hInstance <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param hPrevInstance <20><><EFBFBD>g<EFBFBD>p
|
||||
* @param lpCmdLine <20>R<EFBFBD>}<7D><><EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43>
|
||||
* @param nCmdShow <20>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
* @return <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>R<EFBFBD>[<5B>h
|
||||
*/
|
||||
int runApplication(
|
||||
HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow)
|
||||
{
|
||||
MSG msg;
|
||||
HACCEL hAccelTable;
|
||||
|
||||
// <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>܂<EFBFBD><DC82>B
|
||||
LoadString(hInstance, IDS_APP_TITLE, szTitle, MAX_LOADSTRING);
|
||||
LoadString(hInstance, IDC_BOOKSYNC, szWindowClass, MAX_LOADSTRING);
|
||||
MyRegisterClass(hInstance);
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD>:
|
||||
if (!InitInstance (hInstance, nCmdShow))
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
hAccelTable = LoadAccelerators(hInstance, MAKEINTRESOURCE(IDC_APP_ACCEL));
|
||||
doEvents();
|
||||
|
||||
// <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɍs<C98D><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnWindowShow();
|
||||
|
||||
// <20><><EFBFBD>C<EFBFBD><43> <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W <20><><EFBFBD>[<5B>v:
|
||||
while (GetMessage(&msg, NULL, 0, 0))
|
||||
{
|
||||
if (handleDialogMessage(&msg)) {
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD>X<EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>̂<EFBFBD><CC82>̂<EFBFBD><CC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ꍇ<EFBFBD><EA8D87>
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>B
|
||||
continue;
|
||||
}
|
||||
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
|
||||
{
|
||||
TranslateMessage(&msg);
|
||||
DispatchMessage(&msg);
|
||||
}
|
||||
}
|
||||
|
||||
return (int) msg.wParam;
|
||||
}
|
||||
|
||||
//
|
||||
// <20><EFBFBD>: MyRegisterClass()
|
||||
//
|
||||
// <20>ړI: <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E <20>N<EFBFBD><4E><EFBFBD>X<EFBFBD><58><EFBFBD>o<EFBFBD>^<5E><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
// <20>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>g:
|
||||
//
|
||||
// <20><><EFBFBD>̊<CC8A><D690><EFBFBD><EFBFBD><EFBFBD><EFBFBD>юg<D18E><67><EFBFBD><EFBFBD><EFBFBD>́A'RegisterClassEx' <20><EFBFBD><D690><EFBFBD><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD>ꂽ
|
||||
// Windows 95 <20><><EFBFBD><EFBFBD><EFBFBD>O<EFBFBD><4F> Win32 <20>V<EFBFBD>X<EFBFBD>e<EFBFBD><65><EFBFBD>ƌ݊<C68C><DD8A><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ꍇ<EFBFBD>ɂ̂ݕK<DD95>v<EFBFBD>ł<EFBFBD><C582>B
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>֘A<D698>t<EFBFBD><74><EFBFBD><EFBFBD><EFBFBD>ꂽ
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>`<60><><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD>C<EFBFBD>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>擾<EFBFBD>ł<EFBFBD><C582><EFBFBD><EFBFBD>悤<EFBFBD>ɂ<EFBFBD><C982><EFBFBD><EFBFBD>ɂ́A
|
||||
// <20><><EFBFBD>̊<CC8A><D690><EFBFBD><EFBFBD>Ăяo<D18F><6F><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
//
|
||||
ATOM MyRegisterClass(HINSTANCE hInstance)
|
||||
{
|
||||
WNDCLASSEX wcex;
|
||||
|
||||
wcex.cbSize = sizeof(WNDCLASSEX);
|
||||
|
||||
wcex.style = CS_HREDRAW | CS_VREDRAW;
|
||||
wcex.lpfnWndProc = WndProc;
|
||||
wcex.cbClsExtra = 0;
|
||||
wcex.cbWndExtra = 0;
|
||||
wcex.hInstance = hInstance;
|
||||
wcex.lpszClassName = szWindowClass;
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ŗL<C597>̏<EFBFBD><CC8F><EFBFBD>
|
||||
wcex.hIcon = LoadIcon(hInstance, MAKEINTRESOURCE(IDI_APPICON));
|
||||
wcex.hCursor = LoadCursor(NULL, IDC_ARROW);
|
||||
wcex.hbrBackground = (HBRUSH)(COLOR_WINDOW+1);
|
||||
// wcex.hbrBackground = GetSysColorBrush(COLOR_3DFACE);
|
||||
wcex.lpszMenuName = MAKEINTRESOURCE(IDC_BOOKSYNC);
|
||||
wcex.hIconSm = LoadIcon(wcex.hInstance, MAKEINTRESOURCE(IDI_SMALL));
|
||||
|
||||
return RegisterClassEx(&wcex);
|
||||
}
|
||||
|
||||
//
|
||||
// <20><EFBFBD>: InitInstance(HINSTANCE, int)
|
||||
//
|
||||
// <20>ړI: <20>C<EFBFBD><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X <20>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD>ۑ<EFBFBD><DB91><EFBFBD><EFBFBD>āA<C481><41><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
// <20>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>g:
|
||||
//
|
||||
// <20><><EFBFBD>̊<CC8A><D690>ŁA<C581>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD><CF90>ŃC<C583><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X <20>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD>ۑ<EFBFBD><DB91><EFBFBD><EFBFBD>A
|
||||
// <20><><EFBFBD>C<EFBFBD><43> <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>ѕ\<5C><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
|
||||
{
|
||||
HWND hWnd;
|
||||
|
||||
hInst = hInstance; // <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD><CF90>ɃC<C983><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>i<EFBFBD>[<5B><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
|
||||
baseForm->setClass(szWindowClass);
|
||||
baseForm->setTitle(szTitle);
|
||||
hWnd = baseForm->Create(hInstance);
|
||||
if (!hWnd)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
baseForm->ShowWindow(nCmdShow);
|
||||
baseForm->UpdateWindow();
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
//
|
||||
// <20><EFBFBD>: WndProc(HWND, UINT, WPARAM, LPARAM)
|
||||
//
|
||||
// <20>ړI: <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD>̃<EFBFBD><CC83>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
// WM_COMMAND - <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD> <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B>̏<EFBFBD><CC8F><EFBFBD>
|
||||
// WM_PAINT - <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD>̕`<60><>
|
||||
// WM_DESTROY - <20><><EFBFBD>~<7E><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>Ė߂<C496>
|
||||
//
|
||||
//
|
||||
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
LRESULT lResult = baseForm->WndProc(hWnd, message, wParam, lParam);
|
||||
|
||||
return lResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Windows<77>̃C<CC83>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
*
|
||||
* @return <20>C<EFBFBD>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
int doEvents()
|
||||
{
|
||||
MSG msg;
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD>̏<EFBFBD><CC8F><EFBFBD>
|
||||
while (::PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE)) {
|
||||
BOOL bRet = GetMessage(&msg, NULL, 0, 0);
|
||||
if (bRet > 0){
|
||||
if (handleDialogMessage(&msg)) {
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD>X<EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>̂<EFBFBD><CC82>̂<EFBFBD><CC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ꍇ<EFBFBD><EA8D87>
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>B
|
||||
continue;
|
||||
} else {
|
||||
::TranslateMessage(&msg);
|
||||
::DispatchMessage (&msg);
|
||||
}
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "TwrCore.h"
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef BASEDIALOG_H
|
||||
#define BASEDIALOG_H
|
||||
|
||||
|
||||
196
TWR/BaseForm.cpp
196
TWR/BaseForm.cpp
@@ -1,196 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "BaseForm.h"
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃x<CC83>[<5B>X<EFBFBD>N<EFBFBD><4E><EFBFBD>X
|
||||
*/
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
BaseForm::BaseForm()
|
||||
{
|
||||
windowClass = _T("");
|
||||
title = _T("");
|
||||
style = WS_OVERLAPPEDWINDOW;
|
||||
left = CW_USEDEFAULT;
|
||||
top = CW_USEDEFAULT;
|
||||
width = CW_USEDEFAULT;
|
||||
height = 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>f<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
BaseForm::~BaseForm()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param <20>C<EFBFBD><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @return <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND BaseForm::Create(HINSTANCE hInstance)
|
||||
{
|
||||
this->hInstance = hInstance;
|
||||
hWnd = CreateWindow(
|
||||
windowClass,
|
||||
title,
|
||||
style,
|
||||
left,
|
||||
top,
|
||||
width,
|
||||
height,
|
||||
NULL,
|
||||
NULL,
|
||||
hInstance,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>v<EFBFBD><76><EFBFBD>[<5B>V<EFBFBD>W<EFBFBD><57>
|
||||
*
|
||||
* @param hDlg <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param message <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W
|
||||
* @param wParam WPARAM
|
||||
* @param lParam LPARAM
|
||||
* @return <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
LRESULT CALLBACK BaseForm::WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
int wmId, wmEvent;
|
||||
PAINTSTRUCT ps;
|
||||
HDC hdc;
|
||||
LPNMHDR nmhdr;
|
||||
|
||||
this->hWnd = hWnd;
|
||||
this->message = message;
|
||||
this->wParam = wParam;
|
||||
this->lParam = lParam;
|
||||
|
||||
switch (message)
|
||||
{
|
||||
case WM_CREATE:
|
||||
return OnCreate();
|
||||
case WM_COMMAND:
|
||||
wmId = LOWORD(wParam);
|
||||
wmEvent = HIWORD(wParam);
|
||||
|
||||
return OnCommand(wmId, wmEvent);
|
||||
case WM_NOTIFY:
|
||||
nmhdr = (LPNMHDR)lParam;
|
||||
|
||||
return OnNotify(nmhdr);
|
||||
case WM_PAINT:
|
||||
hdc = BeginPaint(hWnd, &ps);
|
||||
// TODO: <20>`<60><><EFBFBD>R<EFBFBD>[<5B>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɒlj<C992><C789><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>...
|
||||
EndPaint(hWnd, &ps);
|
||||
break;
|
||||
case WM_DESTROY:
|
||||
return OnDestroy();
|
||||
case WM_SYSCOLORCHANGE: // <20>V<EFBFBD>X<EFBFBD>e<EFBFBD><65><EFBFBD>F<EFBFBD><46><EFBFBD>ύX<CF8D>ɂȂ<C982><C882><EFBFBD><EFBFBD>B
|
||||
// <20><><EFBFBD>N<EFBFBD><4E><EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>g<EFBFBD>̈<EFBFBD>(<28><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B>o<EFBFBD>[<5B><><EFBFBD>^<5E>C<EFBFBD>g<EFBFBD><67><EFBFBD>o<EFBFBD>[)<29><><EFBFBD>X<EFBFBD>V<EFBFBD><56><EFBFBD>邽<EFBFBD>߁A<DF81><41><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>g<EFBFBD><67><EFBFBD>B
|
||||
RedrawWindow(hWnd,NULL,NULL,RDW_ERASE | RDW_INVALIDATE | RDW_FRAME);
|
||||
return 0;
|
||||
default:
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>X<EFBFBD>^<5E>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>ݒ肵<DD92>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param newStyle <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>X<EFBFBD>^<5E>C<EFBFBD><43>
|
||||
*/
|
||||
void BaseForm::setStyle(DWORD newStyle)
|
||||
{
|
||||
style = newStyle;
|
||||
if (hWnd != NULL) {
|
||||
SetWindowLongPtr(hWnd, GWL_STYLE, newStyle);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>ƃE<C683>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>̃f<CC83>[<5B>^<5E>̓<EFBFBD><CC93><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param toObj true:<3A>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>̓<EFBFBD><CC93>e<EFBFBD><65><EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>Ɋi<C98A>[<5B><><EFBFBD><EFBFBD><EFBFBD>B
|
||||
* false:<3A>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>̓<EFBFBD><CC93>e<EFBFBD><65><EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>Ɋi<C98A>[<5B><><EFBFBD><EFBFBD><EFBFBD>B
|
||||
*/
|
||||
void BaseForm::UpdateData(bool toObj)
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* WM_COMMAND<4E><44><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param wmId
|
||||
* @param wmEvent
|
||||
* @return <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
LRESULT BaseForm::OnCommand(int wmId, int wmEvent)
|
||||
{
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̏<EFBFBD><CC8F>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g
|
||||
* @return <20>e<EFBFBD>ɂȂ<C982><C882><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND BaseForm::add(TwrWnd *obj)
|
||||
{
|
||||
return ::SetParent(obj->getHwnd(), hWnd);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̏<EFBFBD><CC8F>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param <20>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g
|
||||
* @return <20>e<EFBFBD>ɂȂ<C982><C882><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND BaseForm::add(BaseDialog *obj)
|
||||
{
|
||||
obj->setParent(hWnd);
|
||||
return ::SetParent(obj->getHwnd(), hWnd);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>ꂽ<EFBFBD>Ƃ<EFBFBD><C682>ɌĂяo<D18F><6F><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return 0
|
||||
*/
|
||||
LRESULT BaseForm::OnCreate()
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD>ŃC<C583>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682>ɌĂяo<D18F><6F><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param nmhdr <20>ʒm<CA92><6D><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD>
|
||||
* @return <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
LRESULT BaseForm::OnNotify(LPNMHDR nmhdr)
|
||||
{
|
||||
return DefWindowProc(hWnd, message, wParam, lParam);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD><EFBFBD><C282><EFBFBD><EFBFBD>ۂɌĂяo<D18F><6F><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return 0
|
||||
*/
|
||||
LRESULT BaseForm::OnDestroy()
|
||||
{
|
||||
PostQuitMessage(0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1,68 +0,0 @@
|
||||
#ifndef BASEFORM_H
|
||||
#define BASEFORM_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
#include "BaseDialog.h"
|
||||
|
||||
/**
|
||||
* T windows api WRapper<br>
|
||||
* Window base class
|
||||
*/
|
||||
class BaseForm : public TwrWnd {
|
||||
private:
|
||||
TCHAR *windowClass;
|
||||
TCHAR *title;
|
||||
protected:
|
||||
UINT message;
|
||||
WPARAM wParam;
|
||||
LPARAM lParam;
|
||||
HINSTANCE hInstance;
|
||||
DWORD style;
|
||||
public:
|
||||
BaseForm();
|
||||
virtual ~BaseForm();
|
||||
void setClass(TCHAR *windowClassName) {
|
||||
windowClass = windowClassName;
|
||||
}
|
||||
void setTitle(TCHAR *newTitle) {
|
||||
title = newTitle;
|
||||
}
|
||||
HWND add(TwrWnd *obj);
|
||||
HWND add(BaseDialog *obj);
|
||||
void setStyle(DWORD newStyle);
|
||||
virtual void UpdateData(bool toObj);
|
||||
|
||||
virtual HWND Create(HINSTANCE hInstance);
|
||||
virtual LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam);
|
||||
virtual LRESULT OnCommand(int wmId, int wmEvent);
|
||||
virtual LRESULT OnCreate();
|
||||
virtual LRESULT OnNotify(LPNMHDR nmhdr);
|
||||
virtual LRESULT OnDestroy();
|
||||
|
||||
|
||||
};
|
||||
|
||||
// MFC<46><43>DDX<44><58><EFBFBD>ǂ<EFBFBD><C782>}<7D>N<EFBFBD><4E>
|
||||
#define FDX_Text(toObj, ctl, str, bufLen) \
|
||||
if (toObj) { \
|
||||
SendMessage(ctl->getHwnd(),WM_GETTEXT,bufLen,str); \
|
||||
} else { \
|
||||
SendMessage(ctl->getHwnd(),WM_SETTEXT,(WPARAM)0,str); \
|
||||
}
|
||||
|
||||
#define FDX_Check(toObj, ctl, stat) \
|
||||
if (toObj) { \
|
||||
stat = (SendMessage(ctl->getHwnd(),BM_GETCHECK,0,0) ? true : false); \
|
||||
} else { \
|
||||
SendMessage(ctl->getHwnd(),BM_SETCHECK,(WPARAM)(stat ? 1 : 0),0); \
|
||||
}
|
||||
|
||||
#define FDX_CBIndex(toObj, ctl, index) \
|
||||
if (toObj) { \
|
||||
index = SendMessage(ctl->getHwnd(),CB_GETCURSEL,0,0); \
|
||||
} else { \
|
||||
SendMessage(ctl->getHwnd(),CB_SETCURSEL,(WPARAM)index,0); \
|
||||
}
|
||||
|
||||
|
||||
#endif // BASEFORM_H
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.g
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
// AppliBase.cpp : <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃G<CC83><47><EFBFBD>g<EFBFBD><67> <20>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>`<60><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#include "ModelessDialog.h"
|
||||
|
||||
HWND modelessDialogHandle[10];
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef MODELESSDIALOG_H
|
||||
#define MODELESSDIALOG_H
|
||||
|
||||
|
||||
@@ -1,80 +0,0 @@
|
||||
//#include <windows.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <ctype.h>
|
||||
#include <tchar.h>
|
||||
#include <windows.h>
|
||||
#include "NCFileDialog.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*
|
||||
* @param bOpenFileDialog <20>\<5C>z<EFBFBD><7A><EFBFBD><EFBFBD><EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>̎<EFBFBD><CC8E><EFBFBD><br>
|
||||
* TRUE:[<5B>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD><4A>] <20>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X FALSE:[<5B>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><C282>ĕۑ<C495>]<5D>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X
|
||||
* @param lpszDefExt <20><><EFBFBD><EFBFBD><EFBFBD>̊g<CC8A><67><EFBFBD>q
|
||||
* @param lpszFileName <20><><EFBFBD><EFBFBD><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD>
|
||||
* @param dwFlags <20>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>̐ݒ<CC90><DD92>p<EFBFBD>t<EFBFBD><74><EFBFBD>O
|
||||
* @param lpszFilter <20>t<EFBFBD>B<EFBFBD><42><EFBFBD>^<5E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
* @param pParentWnd <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param dwSize OPENFILENAME<4D>\<5C><><EFBFBD>̂̃T<CC83>C<EFBFBD>Y
|
||||
*/
|
||||
NCFileDialog::NCFileDialog(
|
||||
BOOL bOpenFileDialog,
|
||||
const char *lpszDefExt,
|
||||
const TCHAR *lpszFileName,
|
||||
DWORD dwFlags,
|
||||
const TCHAR *lpszFilter,
|
||||
HWND pParentWnd,
|
||||
DWORD dwSize
|
||||
)
|
||||
{
|
||||
// <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^<5E><><EFBFBD><EFBFBD>m_OpenFileDialog<6F>ɏ<EFBFBD><C98F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
// <20><><EFBFBD><EFBFBD>
|
||||
m_OpenFileDialog = bOpenFileDialog;
|
||||
|
||||
// <20>\<5C><><EFBFBD>̂̃T<CC83>C<EFBFBD>Y
|
||||
memset(&m_ofn,0x00,sizeof(OPENFILENAME));
|
||||
if (dwSize > 0) {
|
||||
m_ofn.lStructSize = dwSize;
|
||||
}else{
|
||||
m_ofn.lStructSize = sizeof(OPENFILENAME);
|
||||
}
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD>̊g<CC8A><67><EFBFBD>q(<28><><EFBFBD>g<EFBFBD>p)
|
||||
m_defExt = lpszDefExt;
|
||||
// <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E
|
||||
m_ofn.hwndOwner = pParentWnd;
|
||||
// <20>t<EFBFBD>B<EFBFBD><42><EFBFBD>^
|
||||
m_ofn.lpstrFilter = lpszFilter;
|
||||
m_ofn.nFilterIndex = 1;
|
||||
// <20>t<EFBFBD><74><EFBFBD>O
|
||||
m_ofn.Flags = dwFlags;
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD><EFBFBD>
|
||||
memset(gotFileName,0x00,sizeof(TCHAR) * _MAX_PATH);
|
||||
if (lpszFileName != NULL) {
|
||||
_tcscpy(gotFileName,lpszFileName);
|
||||
}
|
||||
m_ofn.lpstrFile = gotFileName;
|
||||
m_ofn.nMaxFile = _MAX_PATH;
|
||||
// m_ofn.lpstrTitle = "<22>ݒ<EFBFBD><DD92>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>̎w<CC8E><77>";
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD><4F><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return IDOK:OK<4F>{<7B>^<5E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD> IDCANCEL:<3A>L<EFBFBD><4C><EFBFBD><EFBFBD><EFBFBD>Z<EFBFBD><5A><EFBFBD>{<7B>^<5E><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
int NCFileDialog::DoModal()
|
||||
{
|
||||
int result;
|
||||
|
||||
if (m_OpenFileDialog == FALSE){
|
||||
result = ::GetSaveFileName(&m_ofn);
|
||||
}else{
|
||||
result = ::GetOpenFileName(&m_ofn);
|
||||
}
|
||||
if (result){
|
||||
return IDOK;
|
||||
}else{
|
||||
return IDCANCEL;
|
||||
}
|
||||
}
|
||||
@@ -1,29 +0,0 @@
|
||||
#ifndef NCFileDialog_H
|
||||
#define NCFileDialog_H
|
||||
|
||||
class NCFileDialog {
|
||||
private:
|
||||
TCHAR gotFileName[_MAX_PATH];
|
||||
BOOL m_OpenFileDialog;
|
||||
const char *m_defExt;
|
||||
public:
|
||||
OPENFILENAME m_ofn;
|
||||
|
||||
NCFileDialog(
|
||||
BOOL bOpenFileDialog,
|
||||
const char *lpszDefExt = NULL,
|
||||
const TCHAR *lpszFileName = NULL,
|
||||
DWORD dwFlags = OFN_HIDEREADONLY | OFN_OVERWRITEPROMPT,
|
||||
const TCHAR *lpszFilter = NULL,
|
||||
HWND pParentWnd = NULL,
|
||||
DWORD dwSize = 0
|
||||
);
|
||||
|
||||
int DoModal();
|
||||
TCHAR *GetPathName() { return gotFileName;};
|
||||
OPENFILENAME &GetOFN() {
|
||||
return m_ofn;
|
||||
}
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,58 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrButton.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrButton::TwrButton() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>{<7B>^<5E><><EFBFBD><EFBFBD><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param id <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[ID
|
||||
*/
|
||||
HWND TwrButton::create(HMENU id)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_MULTILINE|BS_CENTER|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
id,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>{<7B>^<5E><><EFBFBD><EFBFBD><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param parent <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param id <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[ID
|
||||
*/
|
||||
HWND TwrButton::create(HWND parent, HMENU id)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_MULTILINE|BS_CENTER|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
parent, // Parent
|
||||
id,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
#ifndef TWRBUTTON_H
|
||||
#define TWRBUTTON_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrButton : public TwrWnd {
|
||||
public:
|
||||
TwrButton();
|
||||
HWND create(HMENU id);
|
||||
HWND create(HWND parent, HMENU id);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,83 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrCheckbox.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrCheckbox::TwrCheckbox() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD><58><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*/
|
||||
HWND TwrCheckbox::create(void)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_AUTOCHECKBOX|BS_LEFT|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
NULL,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD><58><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param parent <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrCheckbox::create(HWND parent)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_AUTOCHECKBOX|BS_LEFT|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
parent, // Parent
|
||||
NULL,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>Ԃ<EFBFBD><D482>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>ꂽ false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>
|
||||
*/
|
||||
bool TwrCheckbox::isChecked(void)
|
||||
{
|
||||
LRESULT result = SendMessage(hWnd, BM_GETCHECK, 0, 0);
|
||||
if (result == BST_CHECKED) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>ݒ肵<DD92>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param checked true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>ꂽ false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>
|
||||
*/
|
||||
void TwrCheckbox::setChecked(bool checked)
|
||||
{
|
||||
if (checked) {
|
||||
SendMessage(hWnd, BM_SETCHECK, (WPARAM)BST_CHECKED, 0);
|
||||
} else {
|
||||
SendMessage(hWnd, BM_SETCHECK, (WPARAM)BST_UNCHECKED, 0);
|
||||
}
|
||||
}
|
||||
@@ -1,15 +0,0 @@
|
||||
#ifndef TWRCHECKBOX_H
|
||||
#define TWRCHECHBOX_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrCheckbox : public TwrWnd {
|
||||
public:
|
||||
TwrCheckbox();
|
||||
HWND create(void);
|
||||
HWND create(HWND parent);
|
||||
bool isChecked(void);
|
||||
void setChecked(bool checked);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrCombobox.h"
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef TWRCOMBOBOX_H
|
||||
#define TWRCOMBOBOX_H
|
||||
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#include "TwrCore.h"
|
||||
|
||||
/** <20>C<EFBFBD><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68> */
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef CORE_H
|
||||
#define CORE_H
|
||||
|
||||
|
||||
@@ -1,54 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrGroupBox.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrGroupBox::TwrGroupBox() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>O<EFBFBD><4F><EFBFBD>[<5B>v<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD><58><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*/
|
||||
HWND TwrGroupBox::create()
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_GROUPBOX,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>O<EFBFBD><4F><EFBFBD>[<5B>v<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD><58><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param parent <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrGroupBox::create(HWND parent)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("BUTTON"),
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE|BS_GROUPBOX,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
parent, // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
#ifndef TWRGROUPBOX_H
|
||||
#define TWRGROUPBOX_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrGroupBox : public TwrWnd {
|
||||
public:
|
||||
TwrGroupBox();
|
||||
HWND create();
|
||||
HWND create(HWND parent);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,154 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
|
||||
#include "commctrl.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrListView.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrListView::TwrListView() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*
|
||||
* @param <20>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>Ɍ<EFBFBD><C98C>ѕt<D195><74><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
TwrListView::TwrListView(HWND newHwnd) : TwrWnd()
|
||||
{
|
||||
hWnd = newHwnd;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B><><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>̃E<CC83>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrListView::create(void)
|
||||
{
|
||||
hWnd = CreateWindowEx(
|
||||
WS_EX_CLIENTEDGE,
|
||||
_T("LISTVIEW"),
|
||||
NULL,
|
||||
WS_CHILD|WS_VISIBLE|LBS_NOINTEGRALHEIGHT|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
NULL,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>ɗv<C997>f<EFBFBD><66><EFBFBD>}<7D><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>}<7D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʒu
|
||||
* @param item <20>lj<EFBFBD><C789><EFBFBD><EFBFBD>镶<EFBFBD><E995B6><EFBFBD><EFBFBD>
|
||||
*/
|
||||
void TwrListView::insertItem(int index, TCHAR *item)
|
||||
{
|
||||
LVITEM itemInfo;
|
||||
|
||||
memset(&itemInfo, 0x00, sizeof(LVITEM));
|
||||
itemInfo.mask = LVIF_TEXT;
|
||||
itemInfo.iItem = index;
|
||||
itemInfo.pszText = item;
|
||||
itemInfo.cchTextMax = _tcslen(item) + 1;
|
||||
|
||||
SendMessage(hWnd, LVM_INSERTITEM , (WPARAM)0, (LPARAM)&itemInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>̃X<CC83>^<5E>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>ݒ肵<DD92>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param newStyle <20>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>^<5E>C<EFBFBD><43>
|
||||
* @return <20>ݒ茋<DD92><E88C8B>
|
||||
*/
|
||||
unsigned int TwrListView::SetExtendedStyle(unsigned int newStyle)
|
||||
{
|
||||
return SendMessage(hWnd, LVM_SETEXTENDEDLISTVIEWSTYLE, (WPARAM)0, (LPARAM)newStyle);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>ɗ<EFBFBD><C997><EFBFBD><EFBFBD>}<7D><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param no <20><><EFBFBD>ԍ<EFBFBD>
|
||||
* @param title <20><><EFBFBD>̃^<5E>C<EFBFBD>g<EFBFBD><67>
|
||||
* @param nFormat <20>t<EFBFBD>H<EFBFBD>[<5B>}<7D>b<EFBFBD>g
|
||||
* @param nWidth <20><><EFBFBD><EFBFBD>
|
||||
* @param nSubItem <20><><EFBFBD>̃T<CC83>u<EFBFBD>A<EFBFBD>C<EFBFBD>e<EFBFBD><65><EFBFBD>̃C<CC83><43><EFBFBD>f<EFBFBD>b<EFBFBD>N<EFBFBD>X
|
||||
* @return <20>}<7D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
int TwrListView::insertColumn(
|
||||
int no,
|
||||
TCHAR *title,
|
||||
int nFormat,
|
||||
int nWidth,
|
||||
int nSubItem
|
||||
)
|
||||
{
|
||||
LVCOLUMN columnInfo;
|
||||
|
||||
columnInfo.mask = LVCF_FMT | LVCF_WIDTH | LVCF_TEXT | LVCF_SUBITEM;
|
||||
columnInfo.pszText = title;
|
||||
columnInfo.fmt = nFormat;
|
||||
columnInfo.cx = nWidth;
|
||||
if (nSubItem > -1) {
|
||||
columnInfo.iSubItem = nSubItem;
|
||||
} else {
|
||||
columnInfo.iSubItem = 0;
|
||||
}
|
||||
|
||||
return SendMessage(hWnd, LVM_INSERTCOLUMN, (WPARAM)no, (LPARAM)(&columnInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>̃`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>ύX<CF8D><58><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>ύX<CF8D><58><EFBFBD><EFBFBD><EFBFBD>s
|
||||
* @param checked true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD> false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>
|
||||
*/
|
||||
void TwrListView::checkItem(int index, bool checked)
|
||||
{
|
||||
ListView_SetCheckState(hWnd, index, (checked ? TRUE : FALSE));
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>̍s<CC8D><73><EFBFBD>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s
|
||||
*/
|
||||
void TwrListView::selectItem(int index)
|
||||
{
|
||||
LVITEM itemInfo;
|
||||
|
||||
itemInfo.mask = LVIF_STATE;
|
||||
itemInfo.iItem = index;
|
||||
itemInfo.state = LVIS_SELECTED ;
|
||||
itemInfo.stateMask = LVIS_SELECTED ;
|
||||
|
||||
SendMessage(hWnd, LVM_SETITEM, (WPARAM)0, (LPARAM)(&itemInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>r<EFBFBD><72><EFBFBD>[<5B>̍s<CC8D>̃`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>擾<EFBFBD><E693BE><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>擾<EFBFBD><E693BE><EFBFBD><EFBFBD><EFBFBD>s
|
||||
* @return true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD> false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>
|
||||
*/
|
||||
bool TwrListView::isChecked(int index)
|
||||
{
|
||||
BOOL state;
|
||||
|
||||
state = ListView_GetCheckState(hWnd, index);
|
||||
|
||||
return (state ? true : false);
|
||||
}
|
||||
|
||||
@@ -1,28 +0,0 @@
|
||||
#ifndef TWRLISTVIEW_H
|
||||
#define TWRLISTVIEW_H
|
||||
|
||||
#include "commctrl.h"
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrListView : public TwrWnd {
|
||||
public:
|
||||
TwrListView();
|
||||
TwrListView(HWND newHwnd);
|
||||
|
||||
HWND create(void);
|
||||
void insertItem(int index, TCHAR *item);
|
||||
unsigned int SetExtendedStyle(unsigned int newStyle);
|
||||
int insertColumn(
|
||||
int no,
|
||||
TCHAR *title,
|
||||
int nFormat = LVCFMT_LEFT,
|
||||
int nWidth = -1,
|
||||
int nSubItem = -1
|
||||
);
|
||||
void checkItem(int index, bool checked);
|
||||
void selectItem(int index);
|
||||
bool isChecked(int index);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,100 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrListbox.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrListbox::TwrListbox() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*
|
||||
* @param <20>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>Ɍ<EFBFBD><C98C>ѕt<D195><74><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
TwrListbox::TwrListbox(HWND newHwnd) : TwrWnd()
|
||||
{
|
||||
hWnd = newHwnd;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD><58><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*/
|
||||
HWND TwrListbox::create(void)
|
||||
{
|
||||
hWnd = CreateWindowEx(
|
||||
WS_EX_CLIENTEDGE,
|
||||
_T("LISTBOX"),
|
||||
NULL,
|
||||
WS_CHILD|WS_VISIBLE|LBS_NOINTEGRALHEIGHT|WS_TABSTOP,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
NULL,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>ɗv<C997>f<EFBFBD><66><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param item <20>lj<EFBFBD><C789><EFBFBD><EFBFBD>镶<EFBFBD><E995B6><EFBFBD><EFBFBD>
|
||||
*/
|
||||
void TwrListbox::addItem(TCHAR *item)
|
||||
{
|
||||
SendMessage(hWnd, LB_ADDSTRING, 0, (LPARAM)item);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>ꂽ<EFBFBD>v<EFBFBD>f<EFBFBD>̈ʒu<CA92><75><EFBFBD>擾<EFBFBD><E693BE><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return -1:<3A>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD> -1<>ȊO:<3A>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>ꂽ<EFBFBD>ꏊ
|
||||
*/
|
||||
int TwrListbox::getSelectedIndex(void)
|
||||
{
|
||||
LRESULT result = SendMessage(hWnd, LB_GETCURSEL, 0, 0);
|
||||
if (result == LB_ERR) {
|
||||
return -1;
|
||||
} else {
|
||||
return (int)result;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>ɗv<C997>f<EFBFBD><66><EFBFBD>}<7D><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>}<7D><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʒu
|
||||
* @param item <20>lj<EFBFBD><C789><EFBFBD><EFBFBD>镶<EFBFBD><E995B6><EFBFBD><EFBFBD>
|
||||
*/
|
||||
void TwrListbox::insertItem(int index, TCHAR *item)
|
||||
{
|
||||
SendMessage(hWnd, LB_INSERTSTRING , (WPARAM)index, (LPARAM)item);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>̗v<CC97>f<EFBFBD><66><EFBFBD>폜<EFBFBD><ED8F9C><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>폜<EFBFBD><ED8F9C><EFBFBD><EFBFBD><EFBFBD>v<EFBFBD>f<EFBFBD>̈ʒu
|
||||
*/
|
||||
void TwrListbox::removeItem(int index)
|
||||
{
|
||||
SendMessage(hWnd, LB_DELETESTRING , (WPARAM)index, (LPARAM)0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>X<EFBFBD>g<EFBFBD>{<7B>b<EFBFBD>N<EFBFBD>X<EFBFBD>̗v<CC97>f<EFBFBD><66><EFBFBD>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>v<EFBFBD>f<EFBFBD>̈ʒu
|
||||
*/
|
||||
void TwrListbox::selectItem(int index)
|
||||
{
|
||||
SendMessage(hWnd, LB_SETCURSEL , (WPARAM)index, (LPARAM)0);
|
||||
}
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
#ifndef TWRLISTBOX_H
|
||||
#define TWRLISTBOX_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrListbox : public TwrWnd {
|
||||
public:
|
||||
TwrListbox();
|
||||
TwrListbox(HWND newHwnd);
|
||||
|
||||
HWND create(void);
|
||||
void addItem(TCHAR *item);
|
||||
void insertItem(int index, TCHAR *item);
|
||||
void removeItem(int index);
|
||||
void selectItem(int index);
|
||||
int getSelectedIndex(void);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,65 +0,0 @@
|
||||
#include <string.h>
|
||||
#include <windows.h>
|
||||
|
||||
#include "TwrMenu.h"
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD><4E><EFBFBD>X
|
||||
*/
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*
|
||||
* @param <20>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>Ɍ<EFBFBD><C98C>ѕt<D195><74><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
TwrMenu::TwrMenu(HWND wnd)
|
||||
{
|
||||
menuHandle = GetMenu(wnd);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B>̃`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*
|
||||
* @param id <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[ID
|
||||
* @param true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD> false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ȃ<EFBFBD>
|
||||
*/
|
||||
void TwrMenu::CheckMenuItem(int id, bool checked)
|
||||
{
|
||||
MENUITEMINFO info;
|
||||
|
||||
memset(&info, 0, sizeof(MENUITEMINFO));
|
||||
info.cbSize = sizeof(MENUITEMINFO);
|
||||
info.fMask = MIIM_STATE;
|
||||
|
||||
GetMenuItemInfo(menuHandle, id, FALSE, &info);
|
||||
if (checked) {
|
||||
info.fState |= MFS_CHECKED;
|
||||
} else {
|
||||
if (info.fState & MFS_CHECKED) {
|
||||
info.fState ^= MFS_CHECKED;
|
||||
}
|
||||
}
|
||||
SetMenuItemInfo(menuHandle, id, FALSE, &info);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B>̃`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ԃ<EFBFBD><D482>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*
|
||||
* @param item <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[ID
|
||||
* @return true:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD> false:<3A>`<60>F<EFBFBD>b<EFBFBD>N<EFBFBD><4E><EFBFBD>Ȃ<EFBFBD>
|
||||
*/
|
||||
bool TwrMenu::isChecked(int item)
|
||||
{
|
||||
MENUITEMINFO info;
|
||||
|
||||
memset(&info, 0, sizeof(MENUITEMINFO));
|
||||
info.cbSize = sizeof(MENUITEMINFO);
|
||||
info.fMask = MIIM_STATE;
|
||||
|
||||
GetMenuItemInfo(menuHandle, item, FALSE, &info);
|
||||
if (info.fState & MFS_CHECKED) {
|
||||
return true;
|
||||
} else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
#ifndef TWRMENU_H
|
||||
#define TWRMENU_H
|
||||
|
||||
class TwrMenu {
|
||||
private:
|
||||
HMENU menuHandle;
|
||||
public:
|
||||
TwrMenu(HWND wnd);
|
||||
void CheckMenuItem(int id,bool checked);
|
||||
bool isChecked(int item);
|
||||
};
|
||||
|
||||
|
||||
#endif
|
||||
@@ -1,61 +0,0 @@
|
||||
#include <windows.h>
|
||||
|
||||
#include "AppliBase.h"
|
||||
#include "TwrProgress.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrProgress::TwrProgress() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*
|
||||
* @param newHwnd <20>I<EFBFBD>u<EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD>Ɍ<EFBFBD><C98C>ѕt<D195><74><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
TwrProgress::TwrProgress(HWND newHwnd) : TwrWnd()
|
||||
{
|
||||
hWnd = newHwnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD>X<EFBFBD>o<EFBFBD>[<5B>͈̔͂<CD88><CD82>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*
|
||||
* @param min <20>ŏ<EFBFBD><C58F>l
|
||||
* @param max <20>ő<EFBFBD><C591>l
|
||||
*/
|
||||
void TwrProgress::setRange(unsigned int min, unsigned int max)
|
||||
{
|
||||
::SendMessage(hWnd, PBM_SETRANGE, 0, (LPARAM)MAKELPARAM(min, max));
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD>X<EFBFBD>o<EFBFBD>[<5B>̐i<CC90>ޕ<EFBFBD><DE95><EFBFBD><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*
|
||||
* @param step <20>i<EFBFBD>ޕ<EFBFBD>
|
||||
*/
|
||||
void TwrProgress::setStep(int step)
|
||||
{
|
||||
::SendMessage(hWnd, PBM_SETSTEP, (WPARAM)step, (LPARAM)0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD>X<EFBFBD>o<EFBFBD>[<5B>̈ʒu<CA92><75><EFBFBD>ݒ肷<DD92><E882B7><EFBFBD>B
|
||||
*
|
||||
* @param pos <20>ʒu
|
||||
*/
|
||||
void TwrProgress::setPos(int pos)
|
||||
{
|
||||
::SendMessage(hWnd, PBM_SETPOS, (WPARAM)pos, (LPARAM)0);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD>X<EFBFBD>o<EFBFBD>[<5B>̒l<CC92><6C><EFBFBD>i<EFBFBD>߂<EFBFBD><DF82>B
|
||||
*/
|
||||
void TwrProgress::stepIt(void)
|
||||
{
|
||||
::SendMessage(hWnd, PBM_STEPIT, (WPARAM)0, (LPARAM)0);
|
||||
}
|
||||
|
||||
@@ -1,19 +0,0 @@
|
||||
#ifndef TWRPROGRESS_H
|
||||
#define TWRPROGRESS_H
|
||||
|
||||
#include <commctrl.h>
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrProgress : public TwrWnd {
|
||||
|
||||
public:
|
||||
TwrProgress();
|
||||
TwrProgress(HWND newHwnd);
|
||||
|
||||
void setRange(unsigned int min, unsigned int max);
|
||||
void setStep(int step);
|
||||
void setPos(int pos);
|
||||
void stepIt(void);
|
||||
};
|
||||
|
||||
#endif
|
||||
104
TWR/TwrTab.cpp
104
TWR/TwrTab.cpp
@@ -1,104 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include <string.h>
|
||||
#include "CommCtrl.h"
|
||||
|
||||
#include "AppliBase.h"
|
||||
#include "TwrTab.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrTab::TwrTab() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>^<5E>u<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>^<5E>u<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD>̃E<CC83>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrTab::create()
|
||||
{
|
||||
hWnd = CreateWindowEx(
|
||||
WS_EX_LEFT,
|
||||
WC_TABCONTROL,
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>^<5E>u<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param parent <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @return <20>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>^<5E>u<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD>̃E<CC83>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrTab::create(HWND parent)
|
||||
{
|
||||
hWnd = CreateWindowEx(
|
||||
WS_EX_LEFT,
|
||||
WC_TABCONTROL,
|
||||
title.c_str(),
|
||||
WS_CHILD|WS_VISIBLE,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
parent, // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>^<5E>u<EFBFBD>R<EFBFBD><52><EFBFBD>g<EFBFBD><67><EFBFBD>[<5B><><EFBFBD><EFBFBD><EFBFBD>lj<EFBFBD><C789><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param title <20>^<5E>u<EFBFBD>̃^<5E>C<EFBFBD>g<EFBFBD><67>
|
||||
*/
|
||||
void TwrTab::add(TCHAR *title)
|
||||
{
|
||||
TCITEM item;
|
||||
|
||||
memset(&item, 0, sizeof(TCITEM));
|
||||
item.mask = TCIF_TEXT;
|
||||
item.pszText = title;
|
||||
item.cchTextMax = (int)((_tcslen(title) + 1) * sizeof(TCHAR));
|
||||
|
||||
INT_PTR count = SendMessage(hWnd, TCM_GETITEMCOUNT, 0 ,0);
|
||||
::SendMessage(hWnd, TCM_INSERTITEM, (WPARAM)count, (LPARAM)&item);
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>ꂽ<EFBFBD>^<5E>u<EFBFBD>̈ʒu<CA92><75><EFBFBD>Ԃ<EFBFBD><D482>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return > -1:<3A>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>ꂽ<EFBFBD>^<5E>u<EFBFBD>̈ʒu -1:<3A>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>Ȃ<EFBFBD>
|
||||
*/
|
||||
int TwrTab::getSelectedIndex(void)
|
||||
{
|
||||
int count = (int)SendMessage(hWnd, TCM_GETCURSEL, 0, 0);
|
||||
|
||||
return count;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>^<5E>u<EFBFBD><75><EFBFBD>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param index <20>I<EFBFBD><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>^<5E>u<EFBFBD>̈ʒu
|
||||
*/
|
||||
void TwrTab::select(int index)
|
||||
{
|
||||
SendMessage(hWnd, TCM_SETCURSEL, (WPARAM)index, 0);
|
||||
|
||||
}
|
||||
|
||||
16
TWR/TwrTab.h
16
TWR/TwrTab.h
@@ -1,16 +0,0 @@
|
||||
#ifndef TWRTAB_H
|
||||
#define TWRTAB_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrTab : public TwrWnd {
|
||||
public:
|
||||
TwrTab();
|
||||
HWND create();
|
||||
HWND create(HWND parent);
|
||||
void add(TCHAR *title);
|
||||
int getSelectedIndex(void);
|
||||
void select(int index);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,57 +0,0 @@
|
||||
#include "stdafx.h"
|
||||
#include "AppliBase.h"
|
||||
#include "TwrText.h"
|
||||
|
||||
/**
|
||||
* <20>R<EFBFBD><52><EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
TwrText::TwrText() : TwrWnd()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>X<EFBFBD>^<5E>e<EFBFBD>B<EFBFBD>b<EFBFBD>N<EFBFBD>e<EFBFBD>L<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>^<5E>e<EFBFBD>B<EFBFBD>b<EFBFBD>N<EFBFBD>e<EFBFBD>L<EFBFBD>X<EFBFBD>g<EFBFBD>̃E<CC83>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrText::create()
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("STATIC"),
|
||||
title.c_str(),
|
||||
WS_CHILD | WS_VISIBLE,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
GetDesktopWindow(), // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>X<EFBFBD>^<5E>e<EFBFBD>B<EFBFBD>b<EFBFBD>N<EFBFBD>e<EFBFBD>L<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @param parent <20>e<EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>̃n<CC83><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @return <20>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>X<EFBFBD>^<5E>e<EFBFBD>B<EFBFBD>b<EFBFBD>N<EFBFBD>e<EFBFBD>L<EFBFBD>X<EFBFBD>g<EFBFBD>̃E<CC83>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
*/
|
||||
HWND TwrText::create(HWND parent)
|
||||
{
|
||||
hWnd = CreateWindow(
|
||||
_T("STATIC"),
|
||||
title.c_str(),
|
||||
WS_CHILD | WS_VISIBLE,
|
||||
left, // X
|
||||
top, // Y
|
||||
width, // Width
|
||||
height, // Height
|
||||
parent, // Parent
|
||||
(HMENU)IDC_STATIC,
|
||||
hInst,
|
||||
NULL);
|
||||
|
||||
return hWnd;
|
||||
}
|
||||
@@ -1,13 +0,0 @@
|
||||
#ifndef TWRTEXT_H
|
||||
#define TWRTEXT_H
|
||||
|
||||
#include "TwrWnd.h"
|
||||
|
||||
class TwrText : public TwrWnd {
|
||||
public:
|
||||
TwrText();
|
||||
HWND create();
|
||||
HWND create(HWND parent);
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#include "stdafx.h"
|
||||
#include "TwrWnd.h"
|
||||
|
||||
|
||||
18
TWR/TwrWnd.h
18
TWR/TwrWnd.h
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef TWRWND_H
|
||||
#define TWRWND_H
|
||||
|
||||
|
||||
@@ -1,246 +0,0 @@
|
||||
// AppliBase.cpp : <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃G<CC83><47><EFBFBD>g<EFBFBD><67> <20>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>`<60><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
|
||||
#include "stdafx.h"
|
||||
#include "commctrl.h"
|
||||
|
||||
#include "TwrCore.h"
|
||||
#include "WindowAppliBase.h"
|
||||
#include "ModelessDialog.h"
|
||||
|
||||
// <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD>:
|
||||
TCHAR szTitle[MAX_LOADSTRING]; // <20>^<5E>C<EFBFBD>g<EFBFBD><67> <20>o<EFBFBD>[<5B>̃e<CC83>L<EFBFBD>X<EFBFBD>g
|
||||
TCHAR szWindowClass[MAX_LOADSTRING]; // <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E <20>N<EFBFBD><4E><EFBFBD>X<EFBFBD><58>
|
||||
BaseForm *baseForm;
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>ŗL<C597>̃O<CC83><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD>
|
||||
WindowAppliBase *appObj;
|
||||
|
||||
extern void initModelessCallback(void);
|
||||
|
||||
// <20><><EFBFBD>̃R<CC83>[<5B>h <20><><EFBFBD>W<EFBFBD><57><EFBFBD>[<5B><><EFBFBD>Ɋ܂܂<DC82><DC82><EFBFBD><EFBFBD><EFBFBD><D690>̐錾<CC90><E98CBE><EFBFBD>]<5D><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD>:
|
||||
int runApplication(
|
||||
HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow);
|
||||
BOOL InitInstance(HINSTANCE, int);
|
||||
INT_PTR CALLBACK About(HWND, UINT, WPARAM, LPARAM);
|
||||
bool handleDialogMessage(LPMSG lpMsg);
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>C<EFBFBD><43><EFBFBD><EFBFBD><EFBFBD>[<5B>`<60><>
|
||||
*
|
||||
* @param hInstance <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param hPrevInstance <20><><EFBFBD>g<EFBFBD>p
|
||||
* @param lpCmdLine <20>R<EFBFBD>}<7D><><EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43>
|
||||
* @param nCmdShow <20>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
* @return <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>R<EFBFBD>[<5B>h
|
||||
*/
|
||||
int APIENTRY _tWinMain(HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow)
|
||||
{
|
||||
INITCOMMONCONTROLSEX iccx;
|
||||
iccx.dwSize = sizeof(INITCOMMONCONTROLSEX);
|
||||
iccx.dwICC = ICC_TAB_CLASSES;
|
||||
if (!InitCommonControlsEx(&iccx)) {
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
initModelessDialog();
|
||||
initModelessCallback();
|
||||
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD>ŃA<C583>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>N<EFBFBD><4E><EFBFBD>X<EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD><58><EFBFBD>ݒ肵<DD92>܂<EFBFBD><DC82>B
|
||||
appObj = createAppli();
|
||||
baseForm = appObj->createBaseForm();
|
||||
|
||||
// <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>\<5C><><EFBFBD>O<EFBFBD>̃A<CC83>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnAppliStart(lpCmdLine);
|
||||
|
||||
int result = runApplication(hInstance, hPrevInstance, lpCmdLine, nCmdShow);
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̌<EFBFBD><CC8C>n<EFBFBD><6E><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnAppliEnd();
|
||||
|
||||
delete appObj;
|
||||
return result;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>J<EFBFBD>n
|
||||
*
|
||||
* @param hInstance <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68>
|
||||
* @param hPrevInstance <20><><EFBFBD>g<EFBFBD>p
|
||||
* @param lpCmdLine <20>R<EFBFBD>}<7D><><EFBFBD>h<EFBFBD><68><EFBFBD>C<EFBFBD><43>
|
||||
* @param nCmdShow <20>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
* @return <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>I<EFBFBD><49><EFBFBD>R<EFBFBD>[<5B>h
|
||||
*/
|
||||
int runApplication(
|
||||
HINSTANCE hInstance,
|
||||
HINSTANCE hPrevInstance,
|
||||
LPTSTR lpCmdLine,
|
||||
int nCmdShow)
|
||||
{
|
||||
MSG msg;
|
||||
HACCEL hAccelTable;
|
||||
|
||||
// <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482>܂<EFBFBD><DC82>B
|
||||
LoadString(hInstance, IDS_APP_TITLE, szTitle, MAX_LOADSTRING);
|
||||
LoadString(hInstance, IDS_APP_CLASS, szWindowClass, MAX_LOADSTRING);
|
||||
MyRegisterClass(hInstance);
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD>:
|
||||
if (!InitInstance (hInstance, nCmdShow))
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
hAccelTable = LoadAccelerators(hInstance, MAKEINTRESOURCE(IDC_APP_ACCEL));
|
||||
doEvents();
|
||||
|
||||
// <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ɍs<C98D><73><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>B
|
||||
appObj->OnWindowShow();
|
||||
|
||||
// <20><><EFBFBD>C<EFBFBD><43> <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W <20><><EFBFBD>[<5B>v:
|
||||
while (GetMessage(&msg, NULL, 0, 0))
|
||||
{
|
||||
if (handleDialogMessage(&msg)) {
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD>X<EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>̂<EFBFBD><CC82>̂<EFBFBD><CC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ꍇ<EFBFBD><EA8D87>
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>B
|
||||
continue;
|
||||
}
|
||||
if (!TranslateAccelerator(msg.hwnd, hAccelTable, &msg))
|
||||
{
|
||||
TranslateMessage(&msg);
|
||||
DispatchMessage(&msg);
|
||||
}
|
||||
}
|
||||
|
||||
return (int) msg.wParam;
|
||||
}
|
||||
|
||||
//
|
||||
// <20><EFBFBD>: InitInstance(HINSTANCE, int)
|
||||
//
|
||||
// <20>ړI: <20>C<EFBFBD><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X <20>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD>ۑ<EFBFBD><DB91><EFBFBD><EFBFBD>āA<C481><41><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
// <20>R<EFBFBD><52><EFBFBD><EFBFBD><EFBFBD>g:
|
||||
//
|
||||
// <20><><EFBFBD>̊<CC8A><D690>ŁA<C581>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD><CF90>ŃC<C583><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X <20>n<EFBFBD><6E><EFBFBD>h<EFBFBD><68><EFBFBD><EFBFBD><EFBFBD>ۑ<EFBFBD><DB91><EFBFBD><EFBFBD>A
|
||||
// <20><><EFBFBD>C<EFBFBD><43> <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>쐬<EFBFBD><EC90AC><EFBFBD><EFBFBD><EFBFBD>ѕ\<5C><><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
BOOL InitInstance(HINSTANCE hInstance, int nCmdShow)
|
||||
{
|
||||
HWND hWnd;
|
||||
|
||||
hInst = hInstance; // <20>O<EFBFBD><4F><EFBFBD>[<5B>o<EFBFBD><6F><EFBFBD>ϐ<EFBFBD><CF90>ɃC<C983><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD><58><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>i<EFBFBD>[<5B><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
|
||||
baseForm->setClass(szWindowClass);
|
||||
baseForm->setTitle(szTitle);
|
||||
hWnd = baseForm->Create(hInstance);
|
||||
if (!hWnd)
|
||||
{
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
baseForm->ShowWindow(nCmdShow);
|
||||
baseForm->UpdateWindow();
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
//
|
||||
// <20><EFBFBD>: WndProc(HWND, UINT, WPARAM, LPARAM)
|
||||
//
|
||||
// <20>ړI: <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD>̃<EFBFBD><CC83>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
// WM_COMMAND - <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD> <20><><EFBFBD>j<EFBFBD><6A><EFBFBD>[<5B>̏<EFBFBD><CC8F><EFBFBD>
|
||||
// WM_PAINT - <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E<EFBFBD>̕`<60><>
|
||||
// WM_DESTROY - <20><><EFBFBD>~<7E><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>Ė߂<C496>
|
||||
//
|
||||
//
|
||||
LRESULT CALLBACK WndProc(HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||
{
|
||||
LRESULT lResult = baseForm->WndProc(hWnd, message, wParam, lParam);
|
||||
|
||||
return lResult;
|
||||
}
|
||||
|
||||
/**
|
||||
* Windows<77>̃C<CC83>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
*
|
||||
* @return <20>C<EFBFBD>x<EFBFBD><78><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||
*/
|
||||
int doEvents()
|
||||
{
|
||||
MSG msg;
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD>̏<EFBFBD><CC8F><EFBFBD>
|
||||
while (::PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE)) {
|
||||
BOOL bRet = GetMessage(&msg, NULL, 0, 0);
|
||||
if (bRet > 0){
|
||||
if (handleDialogMessage(&msg)) {
|
||||
// <20><><EFBFBD>b<EFBFBD>Z<EFBFBD>[<5B>W<EFBFBD><57><EFBFBD><EFBFBD><EFBFBD>[<5B>h<EFBFBD><68><EFBFBD>X<EFBFBD>_<EFBFBD>C<EFBFBD>A<EFBFBD><41><EFBFBD>O<EFBFBD>̂<EFBFBD><CC82>̂<EFBFBD><CC82><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ꍇ<EFBFBD><EA8D87>
|
||||
// <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>B
|
||||
continue;
|
||||
} else {
|
||||
::TranslateMessage(&msg);
|
||||
::DispatchMessage (&msg);
|
||||
}
|
||||
} else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>f<EFBFBD>X<EFBFBD>g<EFBFBD><67><EFBFBD>N<EFBFBD>^
|
||||
*/
|
||||
WindowAppliBase::~WindowAppliBase()
|
||||
{
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>N<EFBFBD><4E><EFBFBD>X<EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X<EFBFBD><EFBFBD><F090B690><EFBFBD><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>N<EFBFBD><4E><EFBFBD>X<EFBFBD>̃C<CC83><43><EFBFBD>X<EFBFBD>^<5E><><EFBFBD>X
|
||||
*/
|
||||
BaseForm *WindowAppliBase::createBaseForm()
|
||||
{
|
||||
return new BaseForm();
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̊J<CC8A>n<EFBFBD><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>\<5C><>
|
||||
*/
|
||||
int WindowAppliBase::OnAppliStart(TCHAR *lpCmdLine)
|
||||
{
|
||||
// <20><><EFBFBD>̊<CC8A><D690><EFBFBD><EFBFBD>I<EFBFBD>[<5B>o<EFBFBD>[<5B><><EFBFBD>C<EFBFBD>h<EFBFBD><68><EFBFBD>ăA<C483>v<EFBFBD><76><EFBFBD>ŗL<C597>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD><45><EFBFBD>\<5C><><EFBFBD><EFBFBD><EFBFBD>ꂽ<EFBFBD>Ƃ<EFBFBD><C682>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>\<5C><>
|
||||
*/
|
||||
int WindowAppliBase::OnWindowShow()
|
||||
{
|
||||
// <20><><EFBFBD>̊<CC8A><D690><EFBFBD><EFBFBD>I<EFBFBD>[<5B>o<EFBFBD>[<5B><><EFBFBD>C<EFBFBD>h<EFBFBD><68><EFBFBD>āA<C481><41><EFBFBD><EFBFBD><EFBFBD>̕\<5C><><EFBFBD><EFBFBD><EFBFBD>̏<EFBFBD><CC8F><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
return 0;
|
||||
}
|
||||
|
||||
/**
|
||||
* <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̏I<CC8F><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
*
|
||||
* @return <20>\<5C><>
|
||||
*/
|
||||
int WindowAppliBase::OnAppliEnd()
|
||||
{
|
||||
// <20><><EFBFBD>̊<CC8A><D690><EFBFBD><EFBFBD>I<EFBFBD>[<5B>o<EFBFBD>[<5B><><EFBFBD>C<EFBFBD>h<EFBFBD><68><EFBFBD>ăA<C483>v<EFBFBD><76><EFBFBD>ŗL<C597>̌㏈<CC8C><E38F88><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>܂<EFBFBD><DC82>B
|
||||
return 0;
|
||||
}
|
||||
@@ -1,33 +0,0 @@
|
||||
#pragma once
|
||||
|
||||
#include <windows.h>
|
||||
#include "TwrCore.h"
|
||||
#include "BaseForm.h"
|
||||
#include "../resource.h"
|
||||
|
||||
// <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ʒ<EFBFBD><CA92>`
|
||||
|
||||
void addModelessDialog(HWND dialog);
|
||||
void delModelessDialog(HWND dialog);
|
||||
|
||||
int doEvents();
|
||||
|
||||
class WindowAppliBase : public BaseForm {
|
||||
public:
|
||||
virtual ~WindowAppliBase();
|
||||
virtual BaseForm *createBaseForm();
|
||||
virtual int OnAppliStart(TCHAR *lpCmdLine);
|
||||
virtual int OnWindowShow();
|
||||
virtual int OnAppliEnd();
|
||||
|
||||
};
|
||||
|
||||
// <20>E<EFBFBD>C<EFBFBD><43><EFBFBD>h<EFBFBD>E<EFBFBD>A<EFBFBD>v<EFBFBD><76><EFBFBD><EFBFBD><EFBFBD>ʒ<EFBFBD><CA92>`
|
||||
|
||||
#define MAX_LOADSTRING 100
|
||||
|
||||
extern TCHAR szWindowClass[MAX_LOADSTRING]; // <20><><EFBFBD>C<EFBFBD><43> <20>E<EFBFBD>B<EFBFBD><42><EFBFBD>h<EFBFBD>E <20>N<EFBFBD><4E><EFBFBD>X<EFBFBD><58>
|
||||
|
||||
WindowAppliBase *createAppli();
|
||||
ATOM MyRegisterClass(HINSTANCE hInstance);
|
||||
LRESULT CALLBACK WndProc(HWND, UINT, WPARAM, LPARAM);
|
||||
18
TWR/stdafx.h
18
TWR/stdafx.h
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
// stdafx.h : <20>W<EFBFBD><57><EFBFBD>̃V<CC83>X<EFBFBD>e<EFBFBD><65> <20>C<EFBFBD><43><EFBFBD>N<EFBFBD><4E><EFBFBD>[<5B>h <20>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>̃C<CC83><43><EFBFBD>N<EFBFBD><4E><EFBFBD>[<5B>h <20>t<EFBFBD>@<40>C<EFBFBD><43><EFBFBD>A<EFBFBD>܂<EFBFBD><DC82><EFBFBD>
|
||||
// <20>Q<EFBFBD>Ɖ<C689><F1909482><EFBFBD><EFBFBD><EFBFBD><EFBFBD>A<EFBFBD><41><EFBFBD><EFBFBD><C282>܂<EFBFBD><DC82>ύX<CF8D><58><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>A<EFBFBD>v<EFBFBD><76><EFBFBD>W<EFBFBD>F<EFBFBD>N<EFBFBD>g<EFBFBD><67><EFBFBD>p<EFBFBD>̃C<CC83><43><EFBFBD>N<EFBFBD><4E><EFBFBD>[<5B>h <20>t<EFBFBD>@<40>C<EFBFBD><43>
|
||||
// <20><><EFBFBD>L<EFBFBD>q<EFBFBD><71><EFBFBD>܂<EFBFBD><DC82>B
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
#ifndef TSTRING
|
||||
#define TSTRING
|
||||
|
||||
|
||||
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
// noMeiryoUI.cpp : <20>A<EFBFBD>v<EFBFBD><76><EFBFBD>P<EFBFBD>[<5B>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD>̃G<CC83><47><EFBFBD>g<EFBFBD><67> <20>|<7C>C<EFBFBD><43><EFBFBD>g<EFBFBD><67><EFBFBD><EFBFBD><EFBFBD>`<60><><EFBFBD>܂<EFBFBD><DC82>B
|
||||
//
|
||||
|
||||
@@ -383,6 +401,9 @@ INT_PTR NoMeiryoUI::OnBnClickedOk()
|
||||
SPIF_UPDATEINIFILE | SPIF_SENDCHANGE);
|
||||
|
||||
// <20>F<EFBFBD><46><EFBFBD>Đݒ肷<DD92>邱<EFBFBD>Ƃʼn<C682><C589>ʂ<EFBFBD><CA82><EFBFBD><EFBFBD>t<EFBFBD><74><EFBFBD>b<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
// <20>̂<EFBFBD><CC82><EFBFBD><EFBFBD>AIObit StartMenu 8<><38><EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD>SetSysColors<72><73>
|
||||
// <20>Ăяo<D18F><6F><EFBFBD>Ɖ<EFBFBD><C689><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ȃ<EFBFBD><C882>̂ŌĂяo<D18F><6F><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃɂ<C682><C982><EFBFBD><EFBFBD>B
|
||||
#if 0
|
||||
DWORD btnColor;
|
||||
btnColor = GetSysColor(COLOR_BTNTEXT);
|
||||
|
||||
@@ -391,6 +412,7 @@ INT_PTR NoMeiryoUI::OnBnClickedOk()
|
||||
COLORREF colors[1];
|
||||
colors[0] = btnColor;
|
||||
SetSysColors(1,colorItems,colors);
|
||||
#endif
|
||||
|
||||
return (INT_PTR)TRUE;
|
||||
}
|
||||
@@ -425,6 +447,9 @@ void NoMeiryoUI::OnBnClickedAll()
|
||||
SPIF_UPDATEINIFILE | SPIF_SENDCHANGE);
|
||||
|
||||
// <20>F<EFBFBD><46><EFBFBD>Đݒ肷<DD92>邱<EFBFBD>Ƃʼn<C682><C589>ʂ<EFBFBD><CA82><EFBFBD><EFBFBD>t<EFBFBD><74><EFBFBD>b<EFBFBD>V<EFBFBD><56><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>B
|
||||
// <20>̂<EFBFBD><CC82><EFBFBD><EFBFBD>AIObit StartMenu 8<><38><EFBFBD>N<EFBFBD><4E><EFBFBD><EFBFBD><EFBFBD>Ă<EFBFBD><C482><EFBFBD><EFBFBD>Ƃ<EFBFBD><C682><EFBFBD>SetSysColors<72><73>
|
||||
// <20>Ăяo<D18F><6F><EFBFBD>Ɖ<EFBFBD><C689><EFBFBD><EFBFBD><EFBFBD><EFBFBD>Ȃ<EFBFBD><C882>Ȃ<EFBFBD><C882>̂ŌĂяo<D18F><6F><EFBFBD><EFBFBD><EFBFBD>s<EFBFBD><73><EFBFBD>Ȃ<EFBFBD><C882><EFBFBD><EFBFBD>Ƃɂ<C682><C982><EFBFBD><EFBFBD>B
|
||||
#if 0
|
||||
DWORD btnColor;
|
||||
btnColor = GetSysColor(COLOR_BTNTEXT);
|
||||
|
||||
@@ -433,6 +458,7 @@ void NoMeiryoUI::OnBnClickedAll()
|
||||
COLORREF colors[1];
|
||||
colors[0] = btnColor;
|
||||
SetSysColors(1,colorItems,colors);
|
||||
#endif
|
||||
|
||||
titleFontName = metricsAll.lfCaptionFont.lfFaceName;
|
||||
titleFontName = metricsAll.lfCaptionFont.lfFaceName;
|
||||
@@ -444,6 +470,7 @@ void NoMeiryoUI::OnBnClickedAll()
|
||||
menuFontName = metricsAll.lfCaptionFont.lfFaceName;
|
||||
|
||||
memcpy(&metrics, &metricsAll,sizeof(NONCLIENTMETRICS));
|
||||
memcpy(&iconFont, &iconFontAll,sizeof(LOGFONT));
|
||||
|
||||
UpdateData(false);
|
||||
}
|
||||
18
noMeiryoUI.h
18
noMeiryoUI.h
@@ -1,3 +1,21 @@
|
||||
/*
|
||||
This file is part of noMeiryoUI
|
||||
Copyright (C) 2005,2012,2013 Tatsuhiko Shoji
|
||||
|
||||
This program is free software; you can redistribute it and/or
|
||||
modify it under the terms of the GNU General Public License
|
||||
as published by the Free Software Foundation; either version 2
|
||||
of the License, or (at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
#ifndef MYAPPLI_H
|
||||
#define MYAPPLI_H
|
||||
|
||||
@@ -58,7 +58,7 @@ STYLE DS_SETFONT | DS_MODALFRAME | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_S
|
||||
CAPTION "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!"
|
||||
FONT 10, "<22>l<EFBFBD>r <20>o<EFBFBD>S<EFBFBD>V<EFBFBD>b<EFBFBD>N", 400, 0, 0x80
|
||||
BEGIN
|
||||
LTEXT "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.02",IDC_STATIC,7,7,125,8,SS_NOPREFIX
|
||||
LTEXT "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! Version 2.03",IDC_STATIC,7,7,125,8,SS_NOPREFIX
|
||||
LTEXT "Copyright (C) Tatsu 2005,2012,2013",IDC_STATIC,139,7,132,8
|
||||
LTEXT "<22><><EFBFBD>ׂẴt<CC83>H<EFBFBD><48><EFBFBD>g",IDC_STATIC,7,21,89,12
|
||||
EDITTEXT IDC_EDIT_ALL,102,21,91,12,ES_AUTOHSCROLL | ES_READONLY
|
||||
@@ -143,8 +143,8 @@ END
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 2,0,2,0
|
||||
PRODUCTVERSION 2,0,2,0
|
||||
FILEVERSION 2,0,3,0
|
||||
PRODUCTVERSION 2,0,3,0
|
||||
FILEFLAGSMASK 0x17L
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
@@ -160,13 +160,13 @@ BEGIN
|
||||
BLOCK "041104b0"
|
||||
BEGIN
|
||||
VALUE "CompanyName", "T.Syoji's Personal Development"
|
||||
VALUE "FileDescription", "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!! <20>v<EFBFBD><76><EFBFBD>O<EFBFBD><4F><EFBFBD><EFBFBD><EFBFBD>t<EFBFBD>@<40>C<EFBFBD><43>"
|
||||
VALUE "FileVersion", "2, 0, 2, 0"
|
||||
VALUE "FileDescription", "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!"
|
||||
VALUE "FileVersion", "2, 0, 3, 0"
|
||||
VALUE "InternalName", "noMeiryo"
|
||||
VALUE "LegalCopyright", "Copyright (C) Tatsuhiko Syoji 2005,2012,2013"
|
||||
VALUE "OriginalFilename", "noMeiryo.exe"
|
||||
VALUE "ProductName", "Meiryo UI<55><49><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>炢!!"
|
||||
VALUE "ProductVersion", "2, 0, 2, 0"
|
||||
VALUE "ProductVersion", "2, 0, 3, 0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
|
||||
@@ -218,6 +218,10 @@
|
||||
RelativePath=".\TWR\ModelessDialog.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrCombobox.cpp"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrCore.cpp"
|
||||
>
|
||||
@@ -233,18 +237,6 @@
|
||||
Filter="h;hpp;hxx;hm;inl;inc;xsd"
|
||||
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
|
||||
>
|
||||
<File
|
||||
RelativePath=".\TWR\BaseDialog.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\DialogAppliBase.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\ModelessDialog.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\noMeiryoUI.h"
|
||||
>
|
||||
@@ -261,14 +253,38 @@
|
||||
RelativePath=".\targetver.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrCore.h"
|
||||
<Filter
|
||||
Name="TWR"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrWnd.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\AppliBase.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\BaseDialog.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\DialogAppliBase.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\ModelessDialog.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\stdafx.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrCore.h"
|
||||
>
|
||||
</File>
|
||||
<File
|
||||
RelativePath=".\TWR\TwrWnd.h"
|
||||
>
|
||||
</File>
|
||||
</Filter>
|
||||
</Filter>
|
||||
<Filter
|
||||
Name="<22><><EFBFBD>\<5C>[<5B>X <20>t<EFBFBD>@<40>C<EFBFBD><43>"
|
||||
|
||||
Reference in New Issue
Block a user