Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions WinHTTrack/MainTab.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,18 @@ void CMainTab::AddControlPages()
AddPage(&m_option3); /* Expert */
}

/* The pages are built before a first run knows its language, so each one re-reads its
title here. It must happen before the base creates the sheet: comctl32 sizes the tab
strip from the captions in effect then, and relabelling afterwards loses a row. */
INT_PTR CMainTab::DoModal()
{
m_option1.SetLangTitle(); m_option2.SetLangTitle(); m_option3.SetLangTitle();
m_option4.SetLangTitle(); m_option5.SetLangTitle(); m_option6.SetLangTitle();
m_option7.SetLangTitle(); m_option8.SetLangTitle(); m_option9.SetLangTitle();
m_option10.SetLangTitle(); m_option11.SetLangTitle();
return CPropertySheet::DoModal();
}

void CMainTab::DefineDefaultProxy()
{
while(GetPageCount()>0)
Expand Down
3 changes: 3 additions & 0 deletions WinHTTrack/MainTab.h
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,9 @@ class CMainTab : public CPropertySheet
CMainTab(UINT nIDCaption, CWnd* pParentWnd = NULL, UINT iSelectPage = 0);
CMainTab(LPCTSTR pszCaption, CWnd* pParentWnd = NULL, UINT iSelectPage = 0);

public:
virtual INT_PTR DoModal();

protected:
void AddControlPages(void);

Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab1.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab1, CPropertyPage)

COptionTab1::COptionTab1() : CPropertyPage(COptionTab1::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab1::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT1); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT1);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab1::COptionTab1() : CPropertyPage(COptionTab1::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab1)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab1.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class COptionTab1 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab1();
~COptionTab1();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab10.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,22 @@ extern "C" {

IMPLEMENT_DYNCREATE(COptionTab10, CPropertyPage)

COptionTab10::COptionTab10() : CPropertyPage(COptionTab10::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab10::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT10); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT10);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab10::COptionTab10() : CPropertyPage(COptionTab10::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab10)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab10.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class COptionTab10 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab10();
~COptionTab10();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab11.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab11, CPropertyPage)

COptionTab11::COptionTab11() : CPropertyPage(COptionTab11::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab11::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT11); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT11);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab11::COptionTab11() : CPropertyPage(COptionTab11::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//{{AFX_DATA_INIT(COptionTab11)
m_ext1 = _T("");
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab11.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class COptionTab11 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab11();
~COptionTab11();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab2.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab2, CPropertyPage)

COptionTab2::COptionTab2() : CPropertyPage(COptionTab2::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab2::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT2); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT2);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab2::COptionTab2() : CPropertyPage(COptionTab2::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab2)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab2.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ class COptionTab2 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab2();
~COptionTab2();
CBuildOptions Bopt;
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab3, CPropertyPage)

COptionTab3::COptionTab3() : CPropertyPage(COptionTab3::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab3::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT3); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT3);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab3::COptionTab3() : CPropertyPage(COptionTab3::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab3)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab3.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class COptionTab3 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab3();
~COptionTab3();
int modify;
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab4.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab4, CPropertyPage)

COptionTab4::COptionTab4() : CPropertyPage(COptionTab4::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab4::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT4); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT4);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab4::COptionTab4() : CPropertyPage(COptionTab4::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab4)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab4.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class COptionTab4 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab4();
~COptionTab4();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab5.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab5, CPropertyPage)

COptionTab5::COptionTab5() : CPropertyPage(COptionTab5::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab5::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT5); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT5);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab5::COptionTab5() : CPropertyPage(COptionTab5::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab5)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab5.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ class COptionTab5 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab5();
~COptionTab5();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab6.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -54,14 +54,22 @@ extern const char *const FooterPresets[] = {

IMPLEMENT_DYNCREATE(COptionTab6, CPropertyPage)

COptionTab6::COptionTab6() : CPropertyPage(COptionTab6::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab6::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT6); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT6);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab6::COptionTab6() : CPropertyPage(COptionTab6::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab6)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab6.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ class COptionTab6 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab6();
~COptionTab6();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab7.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab7, CPropertyPage)

COptionTab7::COptionTab7() : CPropertyPage(COptionTab7::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab7::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT7); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT7);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab7::COptionTab7() : CPropertyPage(COptionTab7::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab7)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab7.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class COptionTab7 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab7();
~COptionTab7();
const char* GetTip(int id);
Expand Down
16 changes: 12 additions & 4 deletions WinHTTrack/OptionTab8.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -42,14 +42,22 @@ static char THIS_FILE[] = __FILE__;

IMPLEMENT_DYNCREATE(COptionTab8, CPropertyPage)

COptionTab8::COptionTab8() : CPropertyPage(COptionTab8::IDD)
/* Called again before each show: the page is built before a first run knows its
language. The copy is page-owned, since a language change frees the hash string. */
void COptionTab8::SetLangTitle(void)
{
// Patcher titre
if (LANG_T(-1)) { // Patcher en français
m_strCaption = LANG(LANG_IOPT8); // page-owned copy; the hash-table string is freed on a language change
const char *const title = LANG(LANG_IOPT8);
/* English keeps the .rc caption, as it did when this ran only from the constructor. */
if (LANG_T(-1) != 0 && title[0] != '\0') {
m_strCaption = title;
m_psp.pszTitle = m_strCaption;
m_psp.dwFlags|=PSP_USETITLE;
}
}

COptionTab8::COptionTab8() : CPropertyPage(COptionTab8::IDD)
{
SetLangTitle();
m_psp.dwFlags|=PSP_HASHELP;
//
//{{AFX_DATA_INIT(COptionTab8)
Expand Down
1 change: 1 addition & 0 deletions WinHTTrack/OptionTab8.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ class COptionTab8 : public CPropertyPage

// Construction
public:
void SetLangTitle(void);
COptionTab8();
~COptionTab8();
const char* GetTip(int id);
Expand Down
Loading
Loading