[Ttssh2-commit] [4916] Additional settings - Visual tabで、Eterm look-feel をチェックできるようにした。

svnno****@sourc***** svnno****@sourc*****
2012年 5月 1日 (火) 00:11:59 JST


Revision: 4916
          http://sourceforge.jp/projects/ttssh2/svn/view?view=rev&revision=4916
Author:   yutakapon
Date:     2012-05-01 00:11:59 +0900 (Tue, 01 May 2012)
Log Message:
-----------
Additional settings - Visual tabで、Eterm look-feel をチェックできるようにした。
設定変更後、Tera Termを再起動するかどうか問い合わせるようにした。

Modified Paths:
--------------
    trunk/doc/en/html/about/history.html
    trunk/doc/en/html/menu/setup-additional.html
    trunk/doc/en/html/usage/transparent.html
    trunk/doc/ja/html/about/history.html
    trunk/doc/ja/html/menu/setup-additional.html
    trunk/doc/ja/html/usage/transparent.html
    trunk/teraterm/teraterm/addsetting.cpp
    trunk/teraterm/teraterm/ttermpro.rc
    trunk/teraterm/ttpcmn/ttcmn.c
    trunk/teraterm/ttpdlg/ttdlg.c

-------------- next part --------------
Modified: trunk/doc/en/html/about/history.html
===================================================================
--- trunk/doc/en/html/about/history.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/en/html/about/history.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -60,6 +60,7 @@
         <ul>
           <li>Environment variable strings(%variableName%) can be included in the ini file path.</li>
           <li>added an image file specified configuration(theme\ImageFile.INI).</li>
+          <li>Enabled the "Eterm lookfeel" checkbox on the <a href="../menu/setup-additional.html">Additional settings dialog</a>.</li>
         </ul></li>
       <li>Macro
         <ul>

Modified: trunk/doc/en/html/menu/setup-additional.html
===================================================================
--- trunk/doc/en/html/menu/setup-additional.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/en/html/menu/setup-additional.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -227,7 +227,7 @@
 
       <dt>Eterm lookfeel</dt>
       <dd>
-	Tera Term window looks like Eterm-lookfeel background transparency. Not supported.
+	Tera Term window looks like Eterm-lookfeel background transparency.
       </dd>
     </dl>
 

Modified: trunk/doc/en/html/usage/transparent.html
===================================================================
--- trunk/doc/en/html/usage/transparent.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/en/html/usage/transparent.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -31,7 +31,7 @@
 
 <p>
 In this type Tera Term window looks like Eterm background transparency. If this function is enabled, Tera Term window becomes background transparency and mixes the wallpaper with your specified image file(*.jpg).<br>
-Please edit the "BGEnable=on" in the teraterm.ini file because you can not configure the value in "Visual" tab on <a href="../menu/setup-additional.html">[Setup] Additonal settings</a>.
+Please edit the "BGEnable=on" in the teraterm.ini file, or you can configure the value in "Visual" tab on <a href="../menu/setup-additional.html">[Setup] Additonal settings</a>.
 </p>
 
 <p>

Modified: trunk/doc/ja/html/about/history.html
===================================================================
--- trunk/doc/ja/html/about/history.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/ja/html/about/history.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -60,6 +60,7 @@
         <ul>
           <li>ini\x83t\x83@\x83C\x83\x8B\x83p\x83X\x82Ɋ‹\xAB\x95ϐ\x94\x95\xB6\x8E\x9A\x97\xF1(%variableName%)\x82\xF0\x8A܂߂\xE7\x82\xEA\x82\xE9\x82悤\x82ɂ\xB5\x82\xBD\x81B</li>
           <li>\x89摜\x83t\x83@\x83C\x83\x8B\x8Ew\x92\xE8\x90ݒ\xE8(theme\ImageFile.INI)\x82\xF0\x92lj\xC1\x82\xB5\x82\xBD\x81B</li>
+          <li><a href="../menu/setup-additional.html">Additional settings\x83_\x83C\x83A\x83\x8D\x83O</a>\x82\xCCVisual\x83^\x83u\x82ŁA\x97L\x8C\xF8\x89\xBB\x82ł\xAB\x82\xE9\x82悤\x82ɂ\xB5\x82\xBD\x81B</li>
         </ul></li>
       <li>\x83}\x83N\x83\x8D
         <ul>

Modified: trunk/doc/ja/html/menu/setup-additional.html
===================================================================
--- trunk/doc/ja/html/menu/setup-additional.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/ja/html/menu/setup-additional.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -224,7 +224,7 @@
 
       <dt>Eterm lookfeel</dt>
       <dd>
-	Eterm\x95\x97\x82̔\xBC\x93\xA7\x96\xBE\x83E\x83B\x83\x93\x83h\x83E\x82\xF0\x8Eg\x97p\x82\xB7\x82邱\x82Ƃ\xAA\x82ł\xAB\x82܂\xB7\x81B\x8C\xBB\x8D݁A\x93\x96\x8AY\x8D\x80\x96ڂ͕ύX\x95s\x89‚ł\xB7\x81B
+	Eterm\x95\x97\x82̔\xBC\x93\xA7\x96\xBE\x83E\x83B\x83\x93\x83h\x83E\x82\xF0\x8Eg\x97p\x82\xB7\x82邱\x82Ƃ\xAA\x82ł\xAB\x82܂\xB7\x81B
       </dd>
     </dl>
 

Modified: trunk/doc/ja/html/usage/transparent.html
===================================================================
--- trunk/doc/ja/html/usage/transparent.html	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/doc/ja/html/usage/transparent.html	2012-04-30 15:11:59 UTC (rev 4916)
@@ -32,7 +32,7 @@
 
 <p>
 \x82\xB1\x82̋@\x94\\x82\xF0\x8Eg\x82\xA4\x82ƁAEterm\x95\x97\x82̔\xBC\x93\xA7\x96\xBE\x83E\x83B\x83\x93\x83h\x83E\x82\xF0\x8Eg\x97p\x82\xB7\x82邱\x82Ƃ\xAA\x82ł\xAB\x82܂\xB7\x81B\x82\xB1\x82̋@\x94\\x82\xF0\x97L\x8C\xF8\x82ɂ\xB7\x82\xE9\x82ƁATera Term\x82̃E\x83B\x83\x93\x83h\x83E\x82͔\xBC\x93\xA7\x96\xBE\x89\xBB\x82\xB3\x82\xEA\x81A\x95ǎ\x86\x82Ǝw\x92肵\x82\xBD\x89摜\x83t\x83@\x83C\x83\x8B(*.jpg)\x82ƍ\xAC\x8D\x87\x82\xB3\x82\xEA\x82ĕ`\x89悳\x82\xEA\x82\xE9\x82悤\x82ɂȂ\xE8\x82܂\xB7\x81B<br>
-\x82\xB1\x82̋@\x94\\x82́A<a href="../menu/setup-additional.html">[Setup] Additional settings</a> \x82\xCC Visual \x83^\x83u\x82ŗL\x8C\xF8\x82ɂł\xAB\x82Ȃ\xA2\x82\xBD\x82߁A\x92\xBC\x90\xDA teraterm.ini \x82\xCC"BGEnable=on"\x82ƕύX\x82\xB5\x82Ă\xAD\x82\xBE\x82\xB3\x82\xA2\x81B
+\x82\xB1\x82̋@\x94\\x82́A<a href="../menu/setup-additional.html">[Setup] Additional settings</a> \x82\xCC Visual \x83^\x83u\x82ŗL\x8C\xF8\x82ɂ\xB7\x82邩\x81A\x92\xBC\x90\xDA teraterm.ini \x82\xCC"BGEnable=on"\x82ƕύX\x82\xB5\x82Ă\xAD\x82\xBE\x82\xB3\x82\xA2\x81B
 </p>
 
 <p>

Modified: trunk/teraterm/teraterm/addsetting.cpp
===================================================================
--- trunk/teraterm/teraterm/addsetting.cpp	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/teraterm/teraterm/addsetting.cpp	2012-04-30 15:11:59 UTC (rev 4916)
@@ -11,6 +11,7 @@
 #include "teraterm.h"
 #include "tttypes.h"
 #include "ttwinman.h"
+#include "ttcommon.h"
 
 mouse_cursor_t MouseCursor[] = {
 	{"ARROW", IDC_ARROW},
@@ -1003,6 +1004,7 @@
 	int beforeAlphaBlend;
 	char buf[MAXPATHLEN];
 	COLORREF TmpColor;
+	int flag_changed = 0;
 
 	// (1)
 	beforeAlphaBlend = ts.AlphaBlend;
@@ -1017,7 +1019,10 @@
 	// \x83O\x83\x8D\x81[\x83o\x83\x8B\x95ϐ\x94 BGEnable \x82𒼐ڏ\x91\x82\xAB\x8A\xB7\x82\xA6\x82\xE9\x82ƁA\x83v\x83\x8D\x83O\x83\x89\x83\x80\x82\xAA\x97\x8E\x82\xBF\x82邱\x82Ƃ\xAA
 	// \x82\xA0\x82\xE9\x82̂ŃR\x83s\x81[\x82\xF0\x8FC\x90\xB3\x82\xB7\x82\xE9\x82݂̂Ƃ\xB7\x82\xE9\x81B(2005.4.24 yutaka)
 	btn = (CButton *)GetDlgItem(IDC_ETERM_LOOKFEEL);
-	ts.EtermLookfeel.BGEnable = btn->GetCheck();
+	if (ts.EtermLookfeel.BGEnable != btn->GetCheck()) {
+		flag_changed = 1;
+		ts.EtermLookfeel.BGEnable = btn->GetCheck();
+	}
 
 	// (3)
 	listbox = (CListBox *)GetDlgItem(IDC_MOUSE_CURSOR);
@@ -1109,6 +1114,11 @@
 			SetWindowStyle(&ts);
 		}
 	}
+
+	if (flag_changed) {
+		// re-launch
+		RestartTeraTerm(GetSafeHwnd(), &ts);
+	}
 }
 
 

Modified: trunk/teraterm/teraterm/ttermpro.rc
===================================================================
--- trunk/teraterm/teraterm/ttermpro.rc	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/teraterm/teraterm/ttermpro.rc	2012-04-30 15:11:59 UTC (rev 4916)
@@ -114,7 +114,7 @@
 BEGIN
     LTEXT           "&Alpha blend",IDC_ALPHABLEND,10,10,43,8
     EDITTEXT        IDC_ALPHA_BLEND,58,8,28,12,ES_AUTOHSCROLL | ES_NUMBER
-    CONTROL         "&Eterm lookfeel",IDC_ETERM_LOOKFEEL,"Button",BS_AUTOCHECKBOX | WS_DISABLED | WS_TABSTOP,116,8,72,12
+    CONTROL         "&Eterm lookfeel",IDC_ETERM_LOOKFEEL,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,116,8,72,12
     LTEXT           "&Mouse cursor",IDC_MOUSE,10,26,70,8
     LISTBOX         IDC_MOUSE_CURSOR,10,36,48,35,LBS_NOINTEGRALHEIGHT | WS_VSCROLL | WS_TABSTOP
     LTEXT           "&Font Quality",IDC_FONT_QUALITY_LABEL,100,26,70,8

Modified: trunk/teraterm/ttpcmn/ttcmn.c
===================================================================
--- trunk/teraterm/ttpcmn/ttcmn.c	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/teraterm/ttpcmn/ttcmn.c	2012-04-30 15:11:59 UTC (rev 4916)
@@ -88,9 +88,20 @@
 	char path[1024];
 	STARTUPINFO si;
 	PROCESS_INFORMATION pi;
+	char uimsg[MAX_UIMSG];
+	int ret;
 
+	get_lang_msg("MSG_TT_TAKE_EFFECT", uimsg, sizeof(uimsg), 
+		"This option takes effect the next time a session is started.\n"
+		"Are you sure that you want to relaunch Tera Term?"
+		, ts->UILanguageFile);
+	ret = MessageBox(hwnd, uimsg, "Tera Term: Configuration Warning", MB_YESNO | MB_ICONEXCLAMATION | MB_DEFBUTTON2);
+	if (ret != IDYES) 
+		return;
+
 	SendMessage(hwnd, WM_COMMAND, ID_SETUP_SAVE, 0);
-	SendMessage(hwnd, WM_COMMAND, ID_FILE_EXIT, 0);
+	// TODO: \x8E\xA9\x93\xAE\x8FI\x97\xB9\x82\xB3\x82\xB9\x82悤\x82Ƃ\xB7\x82\xE9\x82ƁA\x83A\x83v\x83\x8A\x82\xAA\x97\x8E\x82\xBF\x82\xE9\x8Fꍇ\x82\xAA\x82\xA0\x82\xE9\x81B
+	//SendMessage(hwnd, WM_COMMAND, ID_FILE_EXIT, 0);
 
 	if (GetModuleFileName(NULL, path, sizeof(path)) == 0) {
 		return;

Modified: trunk/teraterm/ttpdlg/ttdlg.c
===================================================================
--- trunk/teraterm/ttpdlg/ttdlg.c	2012-04-30 12:58:55 UTC (rev 4915)
+++ trunk/teraterm/ttpdlg/ttdlg.c	2012-04-30 15:11:59 UTC (rev 4916)
@@ -3216,19 +3216,11 @@
 						// \x8C\xBE\x8C\xEA\x83t\x83@\x83C\x83\x8B\x82\xAA\x95ύX\x82\xB3\x82\xEA\x82Ă\xA2\x82\xBD\x8Fꍇ
 						w = (WORD)GetCurSel(Dialog, IDC_GENLANG_UI);
 						if (w != langui_sel) {
-							int ret;
 							_snprintf_s(ts->UILanguageFile_ini, sizeof(ts->UILanguageFile_ini), _TRUNCATE, 
 								"%s/%s", LANG_PATH, LangUIList[w - 1]);
 
-							get_lang_msg("MSG_TT_TAKE_EFFECT", uimsg, sizeof(uimsg), 
-								"This option takes effect the next time a session is started.\n"
-								"Are you sure that you want to relaunch Tera Term?"
-								, UILanguageFile);
-							ret = MessageBox(Dialog, uimsg, "Tera Term: CONFIGURATION WARNING", MB_YESNO | MB_ICONEXCLAMATION | MB_DEFBUTTON2);
-							if (ret == IDYES) {
-								// re-launch
-								RestartTeraTerm(GetParent(Dialog), ts);
-							}
+							// re-launch
+							RestartTeraTerm(GetParent(Dialog), ts);
 						}
 					}
 



Ttssh2-commit メーリングリストの案内