}
-/*
- * Save a screen dump to a file
- * @param creature_ptr プレーヤーへの参照ポインタ
- * @return なし
+/*!
+ * @brief HTMLで記念撮影するかを問い合わせる
+ * @param なし
+ * @return HTMLでダンプするならTRUE
*/
-void do_cmd_save_screen(player_type *creature_ptr, void(*handle_stuff)(player_type*))
+static bool ask_html_dump(void)
{
- prt(_("記念撮影しますか? [(y)es/(h)tml/(n)o] ", "Save screen dump? [(y)es/(h)tml/(n)o] "), 0, 0);
- bool html_dump = FALSE;
while (TRUE)
{
char c = inkey();
if (c == 'Y' || c == 'y')
- break;
+ {
+ return FALSE;
+ }
else if (c == 'H' || c == 'h')
{
- html_dump = TRUE;
- break;
+ return TRUE;
}
else
{
prt("", 0, 0);
- return;
+ return FALSE;
}
}
+ // コンパイル警告対応.
+ return FALSE;
+}
+
+
+/*
+ * Save a screen dump to a file
+ * @param creature_ptr プレーヤーへの参照ポインタ
+ * @return なし
+ */
+void do_cmd_save_screen(player_type *creature_ptr, void(*handle_stuff)(player_type*))
+{
+ prt(_("記念撮影しますか? [(y)es/(h)tml/(n)o] ", "Save screen dump? [(y)es/(h)tml/(n)o] "), 0, 0);
+ bool html_dump = ask_html_dump();
+
int wid, hgt;
Term_get_size(&wid, &hgt);