Skip to content

Commit

Permalink
ダイアログリソース整理 APPVEYOR_PULL_REQUEST_NUMBER
Browse files Browse the repository at this point in the history
表示非表示をコードで切り替えていたのを変更。
ビルド元ソースの情報は、実行時に変わることはないので埋め込んでしまう。
  • Loading branch information
berryzplus committed Oct 21, 2018
1 parent f2c30b6 commit 48dbf1a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 11 deletions.
11 changes: 2 additions & 9 deletions sakura_core/dlg/CDlgAbout.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -272,15 +272,8 @@ BOOL CDlgAbout::OnInitDialog( HWND hwndDlg, WPARAM wParam, LPARAM lParam )
#ifdef APPVEYOR_SHORTHASH
m_UrlGitHubCommitWnd.SetSubclassWindow( GetItemHwnd( IDC_STATIC_URL_GITHUB_COMMIT ) );
#endif
#if defined(GITHUB_COMMIT_URL_PR_HEAD) && defined(APPVEYOR_PULL_REQUEST_NUMBER)
m_UrlGitHubPRWnd.SetSubclassWindow(GetItemHwnd(IDC_STATIC_URL_GITHUB_PR));
#endif

// GitHub の PR のリンク
#if defined(GITHUB_COMMIT_URL_PR_HEAD) && defined(APPVEYOR_PULL_REQUEST_NUMBER)
::SetWindowText(GetItemHwnd(IDC_STATIC_URL_GITHUB_PR), _T("PR ") _T(APPVEYOR_PULL_REQUEST_NUMBER));
#else
ShowWindow(GetItemHwnd(IDC_STATIC_URL_GITHUB_PR), SW_HIDE);
#ifdef APPVEYOR_PULL_REQUEST_NUMBER
m_UrlGitHubPRWnd.SetSubclassWindow( GetItemHwnd( IDC_STATIC_URL_GITHUB_PR ) );
#endif

// GitHub のリンクのテキスト
Expand Down
4 changes: 3 additions & 1 deletion sakura_core/sakura_rc.rc
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,9 @@ BEGIN
#ifdef APPVEYOR_SHORTHASH
LTEXT APPVEYOR_SHORTHASH, IDC_STATIC_URL_GITHUB_COMMIT, 101, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#endif
LTEXT "PR.", IDC_STATIC_URL_GITHUB_PR, 150, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#ifdef APPVEYOR_PULL_REQUEST_NUMBER
LTEXT "PR " APPVEYOR_PULL_REQUEST_NUMBER, IDC_STATIC_URL_GITHUB_PR, 150, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#endif
EDITTEXT IDC_EDIT_ABOUT, 5, 146, 233, 53, ES_MULTILINE | ES_READONLY | WS_VSCROLL | NOT WS_TABSTOP
DEFPUSHBUTTON "&OK", IDOK, 97, 203, 50, 14
PUSHBUTTON "情報をコピー(&C)", IDC_BUTTON_COPY, 178, 203, 60, 14
Expand Down
4 changes: 3 additions & 1 deletion sakura_lang_en_US/sakura_lang_rc.rc
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,9 @@ BEGIN
#ifdef APPVEYOR_SHORTHASH
LTEXT APPVEYOR_SHORTHASH, IDC_STATIC_URL_GITHUB_COMMIT, 101, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#endif
LTEXT "PR.", IDC_STATIC_URL_GITHUB_PR, 150, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#ifdef APPVEYOR_PULL_REQUEST_NUMBER
LTEXT "PR " APPVEYOR_PULL_REQUEST_NUMBER, IDC_STATIC_URL_GITHUB_PR, 150, 133, 30, 8, SS_NOTIFY | NOT WS_GROUP | WS_TABSTOP
#endif
EDITTEXT IDC_EDIT_ABOUT, 5, 146, 233, 53, ES_MULTILINE | ES_READONLY | WS_VSCROLL | NOT WS_TABSTOP
DEFPUSHBUTTON "&OK", IDOK, 97, 203, 50, 14
PUSHBUTTON "&Copy to Clipboard", IDC_BUTTON_COPY, 178, 203, 60, 14
Expand Down

0 comments on commit 48dbf1a

Please sign in to comment.