/* /////////////////////////////////////////////////////////////////////////////
ezlocal-dish-js モジュール
--------------------------------------------------------------------------------
%dll ; モジュール名
ezlocal-dish-js
%ver ; バージョン
2.1
%date ; 更新日
2024/9/10
%author ; 著作者
MIZUSHIKI
%note
HSP3Dish.jsのローカル動作環境を構築。
nginx(ローカルサーバ環境)を自動インストールします。
*/ /////////////////////////////////////////////////////////////////////////////
#ifndef _debug
#define ezlocalJS(%1=0) logmes ""
#else
#runtime "" ; 通常ランタイムに上書き
#define ezlocalJS(%1=0) if __file__=="???"{ dialog "スクリプトをファイルとして保存する必要があります",1,"ezlocal-dish-js" } else { _ScFileName_@ezLocalDishJs = __file__ : onerror 0 : ezlocal_dish_js } : stop
#include "hspinet.as"
#include "mod_regexp.as"
#module ezLocalDishJs
#uselib "hspext.dll"
#func fxren fxren 5
#if __hspver__ < 14081 ; 0x3701未満
#func pipeexec pipeexec 5
#else
#func pipeexec pipeexec $202
#endif
#func pipeget pipeget $83
#func dirlist2 dirlist2 5
#func dirlist2h dirlist2h 0
#uselib "user32.dll"
#func EnableWindow "EnableWindow" int,int
#cfunc GetDlgCtrlID "GetDlgCtrlID" sptr
#cfunc GetSysColorBrush "GetSysColorBrush" sptr
#cfunc LoadCursor "LoadCursorA" sptr,sptr
#func SetClassLong "SetClassLongA" sptr,sptr,sptr
#func SetWindowPos "SetWindowPos" sptr,sptr,sptr,sptr,sptr,sptr,sptr
#func ShowWindow "ShowWindow" int, int
#uselib "gdi32.dll"
#func SetBkMode "SetBkMode" sptr,sptr
#func SetTextColor "SetTextColor" sptr,sptr
#uselib "shlwapi.dll"
#func PathIsDirectory "PathIsDirectoryA" sptr
#uselib "msvcrt"
#func rename "rename" str, str
#uselib "qrcodelib.dll"
#func QRcode_encodeString "QRcode_encodeString" str,int,int,int,int
#func QRcode_free "QRcode_free" int
// マクロ
#define AnonLabel %tanonymouslabel *%i:if(0):*%o:if(1)
#if __hspver__ < 13573 ; HSP3.5beta5未満
#undef mes
#define global mes(%1,%2=0) mes@hsp %1:if %2{pos ginfo_cx+ginfo_mesx,ginfo_cy-ginfo_mesy}:
#endif
// 未初期化対処
res = 0
result = ""
WshShell = 0
created_apache_controller = 0
_ScFileName_@ezLocalDishJs = ""
idchkbox_landscapefit = 0
hStatic_noticeNonIni = 0
showed_localhost_link = 0
bmscr = 0
hbrush = 0
p = 0
refs = ""
dummy = ""
topfoldername_unzip = ""
d2size = 0
pfolderw = 0
scriptSource = ""
inifilesource = ""
htmlsource = ""
tooltip_inited = 0
mrefRefstr = ""
#deffunc ezlocal_dish_js
//----------------
// ディレクトリ確保
//----------------
_dir_cur_ = dir_cur
exist _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8) ; 既にカレントディレクトリが変更されてないか確認
if strsize == -1 : dialog "すでにカレントディレクトリが変更されている可能性があります。\n\nなるべくスクリプトの冒頭かつ #include \"hsp3dish.as\" の真下で ezlocal-dish-js をインクルードしてください。", 1, "ezlocal-dish-js" : end
//----------------
// qrcodelib.dll 確認、出力
//----------------
if varptr(QRcode_encodeString) == 0 {
dialog "qrcodelib.dll が検出されませんでした。\nカレントディレクトリにファイルを出力してもよろしいですか?\n\nカレントディレクトリ\n-------------------------\n"+dir_cur, 3, "ezlocal-dish-js"
if stat != 6 : end
OutputQrcodelibDll dir_cur
dialog "qrcodelib.dll を出力しました。\n\nもう一度、「実行」をしてください。", 0, "ezlocal-dish-js"
end
}
//----------------
// 多重起動禁止
//----------------
res = SearchWindow(0,, "hspwnd0", "^ezlocal-dish-js$")
if res != 0 : sendmsg res, 0x0010/*WM_CLOSE*/, 0, 0
//----------------
// window作成
//----------------
screen ginfo_sel, 640, 480
title "ezlocal-dish-js"
oncmd gosub *command, 0x0111/*WM_COMMAND*/
oncmd gosub *ctlcolorstatic, 0x0138/*WM_CTLCOLORSTATIC*/
onexit goto *quit
//----------------
// initialize
//----------------
PATH_NGINX_FOLDER = "C:\\nginx"
exist PATH_NGINX_FOLDER + "\\nginx.exe" : if strsize==-1 : PATH_NGINX_FOLDER = "" ; 後でnginx-1.27.1等のフォルダも調べる
PATH_PHP_FOLDER = ""
htdocsFolderPath = ""
title_DishHelper = ""
check_DebugOut = -1
sdim dhjsFileName_paths, 1024, 1
sdim pipe_ln, 512000
sdim pipe_buf, 512000
sysfont 0
// オプション
chkbox_ezLocalAdjust = 1
chkbox_saveToBrowser = 0
button_openOptions = 0
//----------------
// nginx環境確認
//----------------
if PATH_NGINX_FOLDER == "" {
notesel result
chdir "C:\\"
dirlist result, "nginx*", 5 : res = stat
chdir _dir_cur_
repeat res, 1
noteget refs, res - cnt
refs = "C:\\" + refs
exist refs + "\\nginx.exe" : if strsize != -1 : break
refs = ""
loop
PATH_NGINX_FOLDER = refs
noteunsel
}
if PATH_NGINX_FOLDER != "" {
mes "HSP3Dish.js ローカル環境("+getpath(PATH_NGINX_FOLDER, 8)+")を検出"
sysfont 17 : color 160,160,160
mes " ・アンインストールしたい場合は「"+PATH_NGINX_FOLDER+"」フォルダを削除するだけでOKです。"
sysfont 0 : color
mes ""
}else {
isNoNginxStart = 1
PATH_NGINX_FOLDER = "C:\\nginx"
//----------------
// PC環境情報を取得
//----------------
// PCのビットを確認
newcom WshShell, "WScript.Shell"
PROCESSOR_ARCHITECTURE = WshShell("ExpandEnvironmentStrings","%PROCESSOR_ARCHITECTURE%")
PROCESSOR_ARCHITEW6432 = WshShell("ExpandEnvironmentStrings","%PROCESSOR_ARCHITEW6432%")
delcom WshShell
bitStr = "-x64" ; x64
if PROCESSOR_ARCHITECTURE == "x86" && PROCESSOR_ARCHITEW6432 != "AMD64" : bitStr = "-x86" ; x86
// ダウンロードフォルダ取得
folderPath_downloads = GetKnownFolderPath("{374DE290-123F-4565-9164-39C4925E467B}")
PathIsDirectory folderPath_downloads
if stat == 0 : folderPath_downloads = dirinfo(0x0001001c/*DIRINFO_LOCAL_APPDATA*/) + "\\Temp" ; ユーザー/AppData/Local/Tempフォルダ
//----------------
// nginx ダウンロード, インストール
//----------------
mes "HSP3Dish.js をローカルで実行できるようにする環境を構築"
sysfont 17
mes "" : pos 2, ginfo_cy - ginfo_mesy/2
mes " ・nginx,PHP-FPMをインストールします。(レジストリは変更されません)"
mes " ・Cドライブ直下に「"+PATH_NGINX_FOLDER+"」フォルダが作られます。"
mes " ・アンインストールは「"+PATH_NGINX_FOLDER+"」フォルダを削除するだけでOKです。"
mes ""
objsize 250, 30
button goto "nginx(ローカルサーバ環境)をインストール", *inst_nginx
hw_inst_nginx = objinfo_hwnd(stat)
stop
*inst_nginx
EnableWindow hw_inst_nginx, 0
//----------------
// プログレスバー作成
//----------------
cx = 260
cy = ginfo_cy - 30
pos cx, cy
mes ""
winobj "msctls_progress32", "", , $50000000, 350, 16
hw_Progress = objinfo(stat, 2)
//----------------
// ダウンロード
//----------------
pos cx, cy
mes "nginx ダウンロード中 "+strf("% 4.1f %%",0.0)
// 最新版zipのURLを調査
netinit@
neturl@ "https://nginx.org/en/download.html"
netrequest_get@ ""
do : wait 5 : netexec@ res : until res
sdim buf, netgetv_size@()
netgetv@ buf ; 受信データ
result = submatch(buf, "href=\"\\.?(/download/nginx\\-\\d+\\.\\d+\\.\\d+\\.zip)\"")
if result == "" : mes "zipファイルのURLが見つかりませんでした" : stop
downloadZipUrl = "https://nginx.org" + result
// ダウンロード処理
Downloader downloadZipUrl, folderPath_downloads, AnonLabel{
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx ダウンロード中 "+refstr : redraw 1
sendmsg hw_Progress, $402, int(refstr)
return
}
zipFilePath = refstr
pos 2, cy+16 : mes ""
if zipFilePath == "" : dialog "ダウンロードに失敗しました", 1, "ezlocal-dish-js" : stop ; フォルダ
//----------------
// アーカイブ展開
//----------------
// unzip処理
Unzipper zipFilePath, "C:\\", AnonLabel{
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx ダウンロード完了 → ZIP展開中 "+refstr : redraw 1
sendmsg hw_Progress, $402, int(refstr)
return
}
_nginxPath = refstr
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx ダウンロード完了 → ZIP展開完了" : redraw 1
sendmsg hw_Progress, $402, 0
pos 2, cy+30 : mes ""
fxren _nginxPath, PATH_NGINX_FOLDER
exist zipFilePath
if strsize != -1 : delete zipFilePath
//----------------
// PHP-FPM ダウンロード, インストール
//----------------
//----------------
// ダウンロード
//----------------
color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy
mes "nginx インストール完了 → PHP-FPM ダウンロード中 "+strf("% 4.1f %%",0.0)
// 最新版zipのURLを調査
netinit@
neturl@ "https://windows.php.net/download/"
netrequest_get@ ""
do : wait 5 : netexec@ res : until res
sdim buf, netgetv_size@()
netgetv@ buf ; 受信データ
result = submatch(buf, "href=\"\\.?(/downloads/releases/php\\-\\d+\\.\\d+\\.\\d+\\-nts\\-Win32\\-vs\\d+\\"+bitStr+"\\.zip)\"")
if result == "" : mes "zipファイルのURLが見つかりませんでした" : stop
downloadZipUrl = "https://windows.php.net" + result
// ダウンロード処理
Downloader downloadZipUrl, folderPath_downloads, AnonLabel{
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx インストール完了 → PHP-FPM ダウンロード中 "+refstr : redraw 1
sendmsg hw_Progress, $402, int(refstr)
return
}
zipFilePath = refstr
pos 2, cy+16 : mes ""
if zipFilePath == "" : dialog "ダウンロードに失敗しました", 1, "ezlocal-dish-js" : stop ; フォルダ
//----------------
// アーカイブ展開
//----------------
// unzip処理
Unzipper zipFilePath, PATH_NGINX_FOLDER, AnonLabel{
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx インストール完了 → PHP-FPM ダウンロード完了 → ZIP展開中 "+refstr : redraw 1
sendmsg hw_Progress, $402, int(refstr)
return
}
_nginxPath = refstr
redraw 0 : color 255,255,255 : boxf cx, cy, ginfo_sx, cy+16 : color
pos cx, cy : mes "nginx インストール完了 → PHP-FPM インストール完了" : redraw 1
sendmsg hw_Progress, $402, 0
pos 2, cy+30 : mes ""
fxren _nginxPath, PATH_NGINX_FOLDER + "\\php"
exist zipFilePath
if strsize != -1 : delete zipFilePath
//----------------
// PHP-FPM用にデータ書き換え
//----------------
exist PATH_NGINX_FOLDER + "\\conf\\nginx.conf"
if strsize != -1 {
notesel result : noteload PATH_NGINX_FOLDER + "\\conf\\nginx.conf"
refs = match(result, "^\\s*#location\\s+\\~\\s+\\\\\\.php\\$\\s*\\{,*?\n\\s*#\\s*root\\s+[\\s\\S]+?#\\}") ; 最初の「location / 」内の
if refs != "" {
refs = replace(refs, "#", "")
refs = replace(refs, "(fastcgi_param\\s+SCRIPT_FILENAME\\s+)/scripts(\\$fastcgi_script_name;)", "$1$document_root$2")
result = replace(result, "^\\s*#location\\s+\\~\\s+\\\\\\.php\\$\\s*\\{,*?\n\\s*#\\s*root\\s+[\\s\\S]+?#\\}", refs)
}
notesave PATH_NGINX_FOLDER + "\\conf\\nginx.conf" : noteunsel
}
exist PATH_NGINX_FOLDER + "\\php\\php.ini-development"
if strsize != -1 {
notesel result : noteload PATH_NGINX_FOLDER + "\\php\\php.ini-development"
result = replace(result, "^;extension_dir = \"ext\"", "extension_dir = \"ext\"")
result = replace(result, "^;extension=bz2", "extension=bz2")
result = replace(result, "^;extension=curl", "extension=curl")
result = replace(result, "^;extension=fileinfo", "extension=fileinfo")
result = replace(result, "^;extension=gettext", "extension=gettext")
result = replace(result, "^;extension=mbstring", "extension=mbstring")
result = replace(result, "^;extension=exif", "extension=exif")
result = replace(result, "^;extension=mysqli", "extension=mysqli")
result = replace(result, "^;extension=pdo_mysql", "extension=pdo_mysql")
result = replace(result, "^;extension=pdo_sqlite", "extension=pdo_sqlite")
result = replace(result, "^;extension=sqlite3", "extension=sqlite3")
notesave PATH_NGINX_FOLDER + "\\php\\php.ini" : noteunsel
}
}
// 127.0.0.1(localhost)のrootフォルダを調査
exist PATH_NGINX_FOLDER + "\\conf\\nginx.conf"
if strsize != -1 {
notesel result : noteload PATH_NGINX_FOLDER + "\\conf\\nginx.conf" : noteunsel
result = submatch(result, "^\\s*location\\s+/\\s*\\{([\\s\\S]+?)\\}") ; 最初の「location / 」内の
result = submatch(result, "^\\s*root\\s+(.+?);") ; 「root」がserverのrootであると決め打ち
if result != "" {
result = replace(result, "/", "\\")
result = replace(result, "^\\.\\\\", "")
refs = PATH_NGINX_FOLDER + "\\"
repeat
if strmid(result, 0, 3) != "..\\" : break
result = strmid(result, 3, strlen(result))
refs = getpath(strtrim(refs, 2, '\\'), 32)
loop
PathIsDirectory result
if stat == 0 : htdocsFolderPath = refs + result : else : htdocsFolderPath = refs
}
}
if htdocsFolderPath == "" : htdocsFolderPath = PATH_NGINX_FOLDER + "\\html"
// PHP-FPMフォルダを調査
exist PATH_NGINX_FOLDER + "\\php\\php-cgi.exe"
if strsize != -1 : PATH_PHP_FOLDER = PATH_NGINX_FOLDER + "\\php" : else : PATH_PHP_FOLDER = ""
if PATH_PHP_FOLDER == "" {
notesel result
dirCur = _dir_cur_
chdir getpath(PATH_NGINX_FOLDER, 32)
dirlist result, "php*", 5 : res = stat
chdir _dir_cur_
temp_PATH_NGINX_FOLDER = strtrim(PATH_NGINX_FOLDER, 2, '\\')
repeat res, 1
noteget refs, res - cnt
refs = temp_PATH_NGINX_FOLDER +"\\"+ refs
exist refs + "\\php-cgi.exe" : if strsize != -1 : break
refs = ""
loop
PATH_PHP_FOLDER = refs
noteunsel
}
// /nginx環境確認
//----------------
// HSP3Dish helper
//----------------
sysfont 0
mes "HSP3Dish helper でスクリプトをHTMLソースに変換"
sysfont 17
mes "" : pos 2, ginfo_cy - ginfo_mesy/2
objsize 250, 30
button gosub "HSP3Dish helper 起動", *open_dishelper
objsize 105, 18 : pos ginfo_cx + 265, ginfo_cy-18
button gosub "hsp3dish.ini 編集", *open_dishini
hButton_editHspDishIni = objinfo_hwnd(stat)
SetTooltip objinfo_hwnd(stat), "hsp3dish.iniファイルを開きます。\nezlocal-dish-js独自のオプションもあります。(仕様はマニュアルを参照)"
pos ginfo_cx - 265
mes " ・HSP3Dish helper内の設定は特に変更しなくても大丈夫です。"
mes " ・HSP3Dish helper起動後、ウィンドウ内の ",1:color 255:mes "「変換」ボタン",1:color:mes " を押してください。":pos 2
mes ""
cx=ginfo_cx : cy = ginfo_cy
//----------------
// 出力HTMLをいじるかどうかのオプション
//----------------
exist _dir_cur_ + "\\hsp3dish.ini"
if strsize != -1 {
notesel iniFileSource : noteload _dir_cur_ + "\\hsp3dish.ini" : noteunsel
if match(iniFileSource, "^\\s*chkbox_ezLocalAdjust\\s*=\\s*(\\d+)") != "" : chkbox_ezLocalAdjust = int( submatch(iniFileSource, "^\\s*chkbox_ezLocalAdjust\\s*=\\s*(\\d+)") ) == 1
if match(iniFileSource, "^\\s*chkbox_saveToBrowser\\s*=\\s*(\\d+)") != "" : chkbox_saveToBrowser = int( submatch(iniFileSource, "^\\s*chkbox_saveToBrowser\\s*=\\s*(\\d+)") ) == 1
if match(iniFileSource, "^\\s*chkbox_landscapeFit\\s*=\\s*(\\d+)") != "" : chkbox_landscapeFit = int( submatch(iniFileSource, "^\\s*chkbox_landscapeFit\\s*=\\s*(\\d+)") ) == 1
if match(iniFileSource, "^\\s*button_openOptions\\s*=\\s*(\\d+)") != "" : button_openOptions = int( submatch(iniFileSource, "^\\s*button_openOptions\\s*=\\s*(\\d+)") ) == 1
}
pos 402, ginfo_cy - ginfo_mesy*3 - 50
grpbox "HTML調整オプション", 228, 83
hGrpbox_optionGroup = objinfo_hwnd(stat)
pos ginfo_cx+7, ginfo_cy-63
objsize 213, 18
button gosub "出力HTMLにスマホ表示等の調整を行う",AnonLabel{chkbox_ezLocalAdjust=1-chkbox_ezLocalAdjust:objenable idChkbox_landscapeFit,chkbox_ezLocalAdjust:return} : hChkbox_ezlocalAdjust = objinfo_hwnd(stat) : SetTooltip objinfo_hwnd(stat), "出力するHTMLにいくつかおすすめの調整を行います。\n------\n・スマホ画面に合わせた表示解像度\n・外周枠線の除去\n・システムメッセージボックスを通常非表示、横幅微減\n・ヘッダで非表示にしきれていない要素を非表示に" : sendmsg hChkbox_ezlocalAdjust, $F4, $3 : sendmsg hChkbox_ezlocalAdjust, $F1, chkbox_ezLocalAdjust
pos ginfo_cx+18:objsize 213-18,18: chkbox "スマホ横向き全画面FIT(β機能)", chkbox_landscapeFit : idChkbox_landscapeFit = stat : hChkbox_landscapeFit = objinfo_hwnd(stat) : objenable idChkbox_landscapeFit,chkbox_ezLocalAdjust : SetTooltip objinfo_hwnd(stat), "ゲーム画面が横長サイズのとき、スマホを横向きにしたら全画面FITするようにHTMLを調整します。\n------\n「ページをある程度下までスクロールしてURLバーを消していると、横向きになってもURLバーが表示されず全画面表示になる」という性質を利用しています。" : pos ginfo_cx-18 : objsize 213, 18
chkbox "ブラウザ上にデータ保存できるようにする", chkbox_saveToBrowser : idChkbox_saveToBrowser = stat : hChkbox_saveToBrowser = objinfo_hwnd(stat) : SetTooltip objinfo_hwnd(stat), "HTMLソースにsaveフォルダのようなものが作られアクセスできるような調整を行います。\nHSP上ではsaveフォルダ以下にファイル保存した後「devcontrol \"syncfs\"」を実行することで、ユーザーのブラウザ上に情報を保存できます。"
if $3602 <= __hspver__ && __hspver__ <= $3702 && hspver <= $3702 : chkbox_saveToBrowser = 0 : EnableWindow hChkbox_saveToBrowser, 0 : objprm idChkbox_saveToBrowser, "ブラウザ上データ保存/hsp3.51or3.7β3〜" : objprm idChkbox_saveToBrowser, chkbox_saveToBrowser
objsize 20, 20
button_openOptions = 1 - button_openOptions
pos ginfo_sx-10-20, 5 : button gosub "+", *show_hide_OptionObj : if 0 : *show_hide_OptionObj : {
button_openOptions = 1 - button_openOptions
ShowWindow hButton_editHspDishIni, button_openOptions
ShowWindow hGrpbox_optionGroup, button_openOptions
ShowWindow hChkbox_ezlocalAdjust, button_openOptions
ShowWindow hChkbox_landscapeFit, button_openOptions
ShowWindow hChkbox_saveToBrowser, button_openOptions
return
}
SetTooltip objinfo_hwnd(stat), "追加オプション"
gosub *show_hide_OptionObj
pos cx, cy
sysfont 0
// ファイル名に全角が含まれていたら警告
if match(_ScFileName_@ezLocalDishJs, "[^ -~。-゚]") != "" : dialog "スクリプトファイル名は、必ず「半角英数のみのファイル名(日本語(全角)を使わない)」ようにしてください。", 1, "ezlocal-dish-js"
//----------------
// DishHelper-console, apache, localhostリンク チェック - メインループ
//----------------
// checkルーチンに入る前に既にconsoleが表示されていたらこれを見つけても無視するようにする
hWnd_DishConsole = SearchWindow(0,, "hspwnd0", "^console$")
if hWnd_DishConsole != 0 : mae_hEdit_DishConsole = SearchWindow(hWnd_DishConsole,, "Edit", "") ; 最初のEdit
mae_isRunHttpdExe = -1
createdHtmlName = "" ; HSP3Dish helperによって作成されたHTMLファイル名を記録してフラグとする
repeat
if cnt\2 == 0 : isRunHttpdExe = isRunProcess("nginx.exe") ; 処理が重そうなので2回に1回だけ
//----------------
// DishHelper-check : 「デバッグ情報を出力する」チェックボックスを常に監視
//----------------
gosub *check_dishdebug
//----------------
// DishHelper-console : 「変換」ボタンによってconsoleが書き変わったか常に監視
//----------------
gosub *check_dishconsole
//----------------
// apache - start/stopボタン表示 : consoleによってHTMLが作成されたか、httpd.exeが起動しているか監視
//----------------
if stat == 1 || isRunHttpdExe {
gosub *create_apache_controller
}
if mae_isRunHttpdExe != isRunHttpdExe {
// apacheの起動終了が変化したときボタンの使用可不可も変更
gosub *buttonEnabler_apache_controller
}
mae_isRunHttpdExe = isRunHttpdExe
//----------------
// localhostリンク - dish.js実行準備ができたか監視。OKならURLやフォルダへのリンクを表示する
//----------------
if createdHtmlName != "" && created_apache_controller && isRunHttpdExe {
gosub *show_localhost_link
}
wait 50
loop
stop
//--------------------------------------
// HSP3Dish helper起動
// ・「hsp3dish.js」ボタン押下
// ・「ソーススクリプト」inputにファイルパスを記入
//--------------------------------------
*open_dishelper
//----------------
// ソーススクリプトを検索してdataフォルダが必要そうか軽く調べ無ければ警告する
//----------------
PathIsDirectory _dir_cur_ + "\\data"
if stat == 0 {
exist _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if strsize != -1 {
notesel scriptSource : noteload _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8) : noteunsel
warn_ss = -1 : warn_dotfw = -1
warn_ss = -1 * (match(scriptSource,"^\\s*#include\\s+\"dotfw.as\"")=="") : if warn_ss != -1 : warn_dotfw = 0 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"#pack ") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"#pack\t") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"#epack") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"picload") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"celload") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"mmload") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,".png") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,".bmp") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,".jpg") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,".wav") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"df_loadbgmap") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,"df_setbgpicfile") : if warn_ss != -1 : goto *esc_warn_ss
warn_ss = instr(scriptSource,0,".tmap") : if warn_ss != -1 : goto *esc_warn_ss
*esc_warn_ss
if warn_ss != -1 {
warn_addText = "" : if warn_dotfw != -1 : warn_addText = "\n\n--------------------\n「dotfw.as」を読み込む場合は基本素材である「tamane16.png」や「afont8.png」が必要な他、バーチャルパッドを使う場合は「vpad.png」も必要になります。"
dialog "「data」フォルダがありません。\n\n使用する外部ファイルがある場合は「data」フォルダを作成して、その中に外部ファイルをまとめる必要があるので注意してください。"+warn_addText, 1, "ezlocal-dish-js"
}
}
}
//----------------
// HSP3Dish helper起動
//----------------
if SearchWindow(0,, "hspwnd0", "^HSP3Dish helper") == 0 : exec dir_exe+"\\hsp3dh.exe"
repeat
hWnd_DishHelper = SearchWindow(0,, "hspwnd0", "^HSP3Dish helper")
if hWnd_DishHelper != 0 : title_DishHelper = refstr : break
wait 10
loop
SetWindowPos hWnd_DishHelper,-1,0,0,0,0,3 //ウィンドウを「常に最前面」の状態にする
SetWindowPos hWnd_DishHelper,-2,0,0,0,0,3 //「常に最前面」の状態を解除
//----------------
// 「hsp3dish.js」ボタン押下
//----------------
hButton_hsp3dishjs = SearchWindow(hWnd_DishHelper,, "Button", "^hsp3dish.js$")
if hButton_hsp3dishjs != 0 : sendmsg hWnd_DishHelper, $111/*WM_COMMAND*/, GetDlgCtrlID(hButton_hsp3dishjs) | 0<<16, 0 // Button Push! : wparam(ボタンID | BN_CLICKED等通知コード<<16) を親ウィンドウに送信
// 切り替わり待ち
repeat
if SearchWindow(hWnd_DishHelper,, "Button", "^hsp3dish.js$") == 0 : break
wait 10
loop
//----------------
// 「ソーススクリプト」inputにファイルパスを入力
// ・ver.1.6以下 : data強制
// ・ver.1.94-hsp37beta3以下 : .ezjs必要(helper変換で_debug実行されてる?) ; check-debugのときも.ezjs使う
//----------------
// ver.取得
if instr(title_DishHelper, 0, "ver.") != -1 {
verDouble_DishHelper = double(strmid(title_DishHelper, instr(title_DishHelper, 0, "ver.")+4, 4))
}else {
verDouble_DishHelper = 9.99 ; わからないときは最新扱い
}
// .ezjs使うか調査
flg_use_dhjs = 0
check_DebugOut = -1
if verDouble_DishHelper <= 1.94 && __hspver__ <= 14082 {
// ver.1.94-hsp37beta3以下 : .ezjs使用
flg_use_dhjs = 1
}else {
// check-debugのときも.ezjs使うので確認
hCheck_DebugOut = SearchWindow(hWnd_DishHelper,, "Button", "デバッグ情報を出力する") ; checkbox
if hCheck_DebugOut != 0 {
sendmsg hCheck_DebugOut, $00F0/*BM_GETCHECK*/, 0, 0
check_DebugOut = (stat != 0)
if check_DebugOut : flg_use_dhjs = 1
}
}
// 入力先取得
hEdit_SourceScript = SearchWindow(hWnd_DishHelper,, "Edit", "") ; 最初のEdit
// 入力内容(まずは.hsp)
_ScFileName_path = _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if flg_use_dhjs {
// .ezjs使うとき
exist _ScFileName_path
if strsize != -1 {
// .hspファイルを読み込んで.ezjsを作成
CreateDhjsFile _ScFileName_path : if 0 {
#deffunc local CreateDhjsFile str __ScFileName_path
notesel scriptSource : noteload __ScFileName_path
scriptSource = replace(scriptSource,"#[a-zA-Z0-9_]*include\\s*\"ezlocal-dish-js\\.hsp\"","")
scriptSource = replace(scriptSource,"ezlocaljs","")
dhjsFileName_path__ = _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8+1) + ".ezjs"
notesave dhjsFileName_path__ : noteunsel
return dhjsFileName_path__
}
_dhjsFileName_path = refstr
dhjsFileName_paths(length(dhjsFileName_paths)) = _dhjsFileName_path ; .ezjsは終了時削除のためpathを記憶
_ScFileName_path = _dhjsFileName_path ; .hsp -> .ezjs に上書き
}
}
Sendmsg hEdit_SourceScript, 0xC /*WM_SETTEXT*/, 0, varptr(_ScFileName_path)
// ver.1.6以下 : data強制
if verDouble_DishHelper <= 1.6 {
hEdit_DataFolder = SearchWindow(hWnd_DishHelper,hEdit_SourceScript, "Edit", "") ; 2番目のEdit
_DataFolder_path = _dir_cur_ + "\\data"
Sendmsg hEdit_DataFolder, 0xC /*WM_SETTEXT*/, 0, varptr(_DataFolder_path)
PathIsDirectory _DataFolder_path
if stat == 0 : mkdir "data" ; 無ければ勝手に作っちゃう
}
return
//--------------------------------------
// hsp3dish.ini を開く
//--------------------------------------
*open_dishini
_iniFileName_path = _dir_cur_ + "\\hsp3dish.ini"
exist _iniFileName_path
if strsize == -1 {
dialog "hsp3dish.ini が見つかりませんでした。\n\n作成しても良いですか?", 2, "ezlocal-dish-js"
if stat != 6 : return
packopt_wx = 0
packopt_wy = 0
exist _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if strsize != -1 {
notesel scriptSource : noteload _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8) : noteunsel
packopt_wx = int( submatch(scriptSource, "#packopt\\s+xsize\\s+(\\d+)") )
packopt_wy = int( submatch(scriptSource, "#packopt\\s+ysize\\s+(\\d+)") )
if packopt_wx == 0 && packopt_wy == 0 {
// dotfw.as 対応
_wx=0 : _wy=0 : _wz=0
result = submatch(scriptSource, "df_config\\s+\"(.*?)\"")
if result != "" {
_wa=100
_wx = int(submatch(result, "X(\\d+)")) : if _wx==0 : _wx = 320
_wy = int(submatch(result, "Y(\\d+)")) : if _wy==0 : _wy = 240
_wz = int(submatch(result, "Z(\\d+)")) : if _wz==0 : _wz = 300
_wa = int(submatch(result, "A(\\d+)")) : if _wa==0 : _wa = 100
if match(result,"(^|\\s)fc(\\s|$)") != "" : _wx=256 : _wy=224
if match(result,"(^|\\s)sfc(\\s|$)") != "" : _wx=256 : _wy=224
if match(result,"(^|\\s)pce(\\s|$)") != "" : _wx=320 : _wy=224
if match(result,"(^|\\s)md(\\s|$)") != "" : _wx=320 : _wy=224
if match(result,"(^|\\s)gb(\\s|$)") != "" : _wx=160 : _wy=144
if match(result,"(^|\\s)gba(\\s|$)") != "" : _wx=240 : _wy=160
if match(result,"(^|\\s)nds(\\s|$)") != "" : _wx=256 : _wy=192
if match(result,"(^|\\s)3ds(\\s|$)") != "" : _wx=320 : _wy=240
if match(result,"(^|\\s)n64(\\s|$)") != "" : _wx=320 : _wy=224
if match(result,"(^|\\s)ngc(\\s|$)") != "" : _wx=640 : _wy=480
if match(result,"(^|\\s)ss(\\s|$)") != "" : _wx=320 : _wy=224
if match(result,"(^|\\s)dc(\\s|$)") != "" : _wx=640 : _wy=480
if match(result,"(^|\\s)ps1(\\s|$)") != "" : _wx=320 : _wy=240
if match(result,"(^|\\s)ps2(\\s|$)") != "" : _wx=640 : _wy=480
if match(result,"(^|\\s)psp(\\s|$)") != "" : _wx=480 : _wy=272
if match(result,"(^|\\s)vita(\\s|$)") != "" : _wx=960 : _wy=544
if match(result,"(^|\\s)msx(\\s|$)") != "" : _wx=256 : _wy=192
if match(result,"(^|\\s)msx2(\\s|$)") != "" : _wx=512 : _wy=424
if match(result,"(^|\\s)appleii(\\s|$)") != "" : _wx=280 : _wy=192
if match(result,"(^|\\s)c64(\\s|$)") != "" : _wx=320 : _wy=200
if match(result,"(^|\\s)pc60(\\s|$)") != "" : _wx=256 : _wy=192
if match(result,"(^|\\s)pc80(\\s|$)") != "" : _wx=320 : _wy=200
if match(result,"(^|\\s)pc88(\\s|$)") != "" : _wx=640 : _wy=200
if match(result,"(^|\\s)pc98(\\s|$)") != "" : _wx=640 : _wy=400
if match(result,"(^|\\s)arcade(\\s|$)") != "" : _wx=224 : _wy=320
if match(result,"(^|\\s)neogeo(\\s|$)") != "" : _wx=320 : _wy=224
packopt_wx = _wx * _wz / 100
packopt_wy = _wy * _wz * _wa / 100 / 100
}
if packopt_wx == 0 | packopt_wy == 0 {
matches result, scriptSource, "df_screen\\s+(\\d*)"
if stat : _wx = int(result(0,1)) : if _wx == 0 : _wx = 320
matches result, scriptSource, "df_screen\\s+\\d*\\s*,\\s*(\\d*)"
if stat : _wy = int(result(0,1)) : if _wy == 0 : _wy = 224
matches result, scriptSource, "df_screen\\s+\\d*\\s*,\\s*\\d*\\s*,\\s*(\\d*)"
if stat : _wz = int(result(0,1)) : if _wz == 0 : _wz = 300
packopt_wx = _wx * _wz / 100
packopt_wy = _wy * _wz / 100
}
if packopt_wx == 0 | packopt_wy == 0 {
matches result, scriptSource, "screen\\s+.*?\\s*,\\s*(\\d*)"
if stat : _wx = int(result(0,1)) : if _wx == 0 : _wx = 320
matches result, scriptSource, "screen\\s+.*?\\s*,\\s*\\d*\\s*,\\s*(\\d*)"
if stat : _wy = int(result(0,1)) : if _wy == 0 : _wy = 224
packopt_wx = _wx
packopt_wy = _wy
}
}
}
if packopt_wx == 0 : packopt_wx = 320
if packopt_wy == 0 : packopt_wy = 480
iniFileSource = "; hsp3dish settings\nwx="+packopt_wx+"\nwy="+packopt_wy+"\nautoscale=0\n\n; ezlocal-dish-js settings\nsx="+packopt_wx+"\nsy="+packopt_wy+"\nchkbox_ezLocalAdjust=1\nchkbox_landscapeFit=0\nchkbox_saveToBrowser=0\nbutton_openOptions=0\n"
notesel iniFileSource : notesave _iniFileName_path : noteunsel
}
exist _dir_cur_ + "\\hsp3dish.ini"
if strsize != -1 {
notesel iniFileSource : noteload _dir_cur_ + "\\hsp3dish.ini"
// ヘッダ
if instr(iniFileSource, 0, "; ezlocal-dish-js settings") == -1 {
iniFileSource += "\n\n; ezlocal-dish-js settings"
}
// sx, sy
if match(iniFileSource, "^\\s*sx\\s*=") == "" {
ini_wx = submatch(iniFileSource, "^\\s*wx\\s*=\\s*(\\d+)")
if ini_wx != "" : ini_sx = ini_wx : else : ini_sx = "320"
iniFileSource += "\nsx="+ini_sx
}
if match(iniFileSource, "^\\s*sy\\s*=") == "" {
ini_wy = submatch(iniFileSource, "^\\s*wy\\s*=\\s*(\\d+)")
if ini_wy != "" : ini_sy = ini_wy : else : ini_sy = "480"
iniFileSource += "\nsy="+ini_sy
}
// chkbox_ezLocalAdjust
if match(iniFileSource, "(^\\s*chkbox_ezLocalAdjust\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_ezLocalAdjust\\s*=\\s*)(\\d+)", "$1"+chkbox_ezLocalAdjust)
}else {
iniFileSource += "\nchkbox_ezLocalAdjust="+chkbox_ezLocalAdjust
}
// chkbox_landscapeFit
if match(iniFileSource, "(^\\s*chkbox_landscapeFit\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_landscapeFit\\s*=\\s*)(\\d+)", "$1"+chkbox_landscapeFit)
}else {
iniFileSource += "\nchkbox_landscapeFit="+chkbox_landscapeFit
}
// chkbox_saveToBrowser
if match(iniFileSource, "(^\\s*chkbox_saveToBrowser\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_saveToBrowser\\s*=\\s*)(\\d+)", "$1"+chkbox_saveToBrowser)
}else {
iniFileSource += "\nchkbox_saveToBrowser="+chkbox_saveToBrowser
}
// button_openOptions
if match(iniFileSource, "(^\\s*button_openOptions\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*button_openOptions\\s*=\\s*)(\\d+)", "$1"+button_openOptions)
}else {
iniFileSource += "\nbutton_openOptions="+button_openOptions
}
notesave _dir_cur_ + "\\hsp3dish.ini" : noteunsel
}
exec _iniFileName_path, 16
return
//--------------------------------------
// DishHelper-check : 「デバッグ情報を出力する」チェックボックスを常に監視
// ・_debugが強制付加されるので#ifndef _debugが使えないため.ezjsを利用する
// ・.ezjsの作成、editへの入力を行う
//--------------------------------------
*check_dishdebug
// HSP3Dish helper取得
hWnd_DishHelper = SearchWindow(0,, "hspwnd0", "^HSP3Dish helper")
if hWnd_DishHelper == 0 : return
title_DishHelper = refstr
if instr(title_DishHelper, 0, "ver.") != -1 {
verDouble_DishHelper = double(strmid(title_DishHelper, instr(title_DishHelper, 0, "ver.")+4, 4))
}else {
verDouble_DishHelper = 99.99 ; わからないときは最新扱い
}
if verDouble_DishHelper <= 1.94 && __hspver__ <= 14082 : return ; hsp37b3以下は常に.ezjsを使うためreturn
// check-debugが変更されたか確認
hCheck_DebugOut = SearchWindow(hWnd_DishHelper,, "Button", "デバッグ情報を出力する") ; checkbox
if hCheck_DebugOut == 0 : return
// check取得
sendmsg hCheck_DebugOut, $00F0/*BM_GETCHECK*/, 0, 0
_check_DebugOut = (stat != 0)
if check_DebugOut == _check_DebugOut : return ; 変わってなかった
check_DebugOut = _check_DebugOut
// 入力先取得、変更
hEdit_SourceScript = SearchWindow(hWnd_DishHelper,, "Edit", "") ; 最初のEdit
// 入力内容(まずは.hsp)
_ScFileName_path = _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if check_DebugOut {
// .ezjs使うとき
exist _ScFileName_path
if strsize != -1 {
// .hspファイルを読み込んで.ezjsを作成
CreateDhjsFile _ScFileName_path
_dhjsFileName_path = refstr
dhjsFileName_paths(length(dhjsFileName_paths)) = _dhjsFileName_path ; .ezjsは終了時削除のためpathを記憶
_ScFileName_path = _dhjsFileName_path ; .hsp -> .ezjs に上書き
}
}
Sendmsg hEdit_SourceScript, 0xC /*WM_SETTEXT*/, 0, varptr(_ScFileName_path)
return
//--------------------------------------
// DishHelper-console : 「変換」ボタンによってconsoleが書き変わったか常に監視
// ・console書き換わりチェック
// ・作成されたHTML等をhtmlフォルダにコピー
//--------------------------------------
*check_dishconsole
//----------------
// console書き換わりチェック
//----------------
// consoleウィンドウハンドル取得
hWnd_DishConsole = SearchWindow(0,, "hspwnd0", "^console$")
if hWnd_DishConsole == 0 : return 0
// consoleウィンドウのEdit取得
hEdit_DishConsole = SearchWindow(hWnd_DishConsole,, "Edit", "") ; 最初のEdit
// 書き換わりチェック
if mae_hEdit_DishConsole == hEdit_DishConsole : return 0
mae_hEdit_DishConsole = hEdit_DishConsole
//----------------
// 作成されたHTML等をhtmlフォルダにコピー
//----------------
// 作成ファイルチェック
sdim text_DishConsole, 64*1024
Sendmsg hEdit_DishConsole, 0xD /*WM_GETTEXT*/, 64*1024, varptr(text_DishConsole)
matches result, text_DishConsole, "\\[(.*?)\\]を作成しました." ; 作成ファイル名取得
num_result = stat
if num_result == 0 : return 0
PathIsDirectory htdocsFolderPath
if stat = 0 : return 0
// ファイルコピー先フォルダの作成
PathIsDirectory htdocsFolderPath+"\\" + getpath(_ScFileName_@ezLocalDishJs, 1+8)
if stat == 0 : dirCur = _dir_cur_ : chdir htdocsFolderPath+"\\" : mkdir getpath(_ScFileName_@ezLocalDishJs, 1+8) : chdir dirCur
// ファイルをコピー
repeat num_result
exist _dir_cur_ + "\\" + result(cnt,1)
if strsize == -1 : continue
if getpath(result(cnt,1),2) == ".html" {
createdHtmlName = result(cnt,1)
// HTML改造
HtmlEzLocalAdjuster _dir_cur_ + "\\" + createdHtmlName
}
bcopy _dir_cur_ + "\\" + result(cnt,1), htdocsFolderPath+"\\" + getpath(_ScFileName_@ezLocalDishJs, 1+8) + "\\" + result(cnt,1)
loop
if instr(text_DishConsole, 0, "not found.") != -1 {
if instr(title_DishHelper, 0, "ver.1.96") != -1 {
// ver.1.96のバグ
dialog "データファイル追加時に「not found」が検出されました。\n\nHSP3Dish helper ver.1.96にはdataフォルダ内のファイルがスクリプトと同じフォルダにも置かれていないとエラーが発生するバグがあります。\n「HSP3アップデーター」を使って「HSP3.7β8の累積アップデート」パッケージをインストールしてver.1.97に更新してください。", 1, "ezlocal-dish-js"
}
}
//----------------
// ezphp.phpも必要ならコピー(なければファイル出力)
//----------------
exist _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if strsize != -1 {
notesel scriptSource : noteload _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8) : noteunsel
if match(scriptSource,"^\\s*#include\\s+\"mod_ezphp.hsp\"") != "" {
exist _dir_cur_ + "\\ezphp.php"
if strsize != -1 {
bcopy _dir_cur_ + "\\ezphp.php", htdocsFolderPath+"\\" + getpath(_ScFileName_@ezLocalDishJs, 1+8) + "\\ezphp.php"
}else {
OutputEzphpPhp htdocsFolderPath+"\\" + getpath(_ScFileName_@ezLocalDishJs, 1+8)
}
}
}
//----------------
// hsp3dish.ini無いときあったほうが良い表示が必要か確認
//----------------
notice_nonIni = 0
_iniFileName_path = _dir_cur_ + "\\hsp3dish.ini"
exist _iniFileName_path
if strsize == -1 {
exist _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8)
if strsize != -1 {
notesel scriptSource : noteload _dir_cur_ + "\\" + getpath(_ScFileName_@ezLocalDishJs, 8) : noteunsel
warn_ss = -1
warn_ss = -1 * (match(scriptSource,"^\\s*#include\\s+\"dotfw.as\"")=="") : if warn_ss != -1 : goto *esc_warn_ss2
warn_ss = -1 * (match(scriptSource,"^\\s*#packopt\\s+\[xy]size")=="") : if warn_ss != -1 : goto *esc_warn_ss2
warn_ss = instr(scriptSource,0,"screen") : if warn_ss != -1 : goto *esc_warn_ss2
warn_ss = instr(scriptSource,0,"df_screen") : if warn_ss != -1 : goto *esc_warn_ss2
warn_ss = instr(scriptSource,0,"df_config") : if warn_ss != -1 : goto *esc_warn_ss2
*esc_warn_ss2
notice_nonIni = (warn_ss != -1)
}
}
if hStatic_noticeNonIni != 0 : ShowWindow hStatic_noticeNonIni, (notice_nonIni != 0)
return 1
//--------------------------------------
// nginx - start/stopボタン表示
//--------------------------------------
*create_apache_controller
; in isRunHttpdExe
if created_apache_controller : return
created_apache_controller = 1
color 235,235,235
boxf 0, ginfo_cy, ginfo_sx, ginfo_cy + 75
y_bottom = ginfo_cy + 75
color
pos , ginfo_cy+5
mes "nginx(ローカルサーバ)の起動"
objsize 100, 20
pos 50, ginfo_cy+15
color 255,160,160 : boxf ginfo_cx-1,ginfo_cy-1,ginfo_cx+100,ginfo_cy+20 : color
button gosub "start", *start_apache
hButton_start_apache = objinfo_hwnd(stat)
EnableWindow hButton_start_apache, isRunHttpdExe==0
pos 200, ginfo_cy-20
button gosub "stop", *stop_apache
hButton_stop_apache = objinfo_hwnd(stat)
EnableWindow hButton_stop_apache, isRunHttpdExe==1
sysfont 17
color 120,120,120
if isNoNginxStart {
pos 350, ginfo_cy-51
mes "※ ",1 : mes "コマンドプロンプトから切り替えたい場合は\n"+PATH_NGINX_FOLDER+"フォルダで 「起動: nginx.exe」\n「停止: nginx.exe -s quit」 を実行してください。"
pos 350, ginfo_cy+3 : color 255,100,100
mes "※ ",1 : mes "初回はファイアウォールの警告が出ます。\n「アクセス許可」ボタンを押してください。"
}else {
pos 350, ginfo_cy-35
mes "※ ",1 : mes "コマンドプロンプトから切り替えたい場合は\n"+PATH_NGINX_FOLDER+"フォルダで 「起動: nginx.exe」\n「停止: nginx.exe -s quit」 を実行してください。"
}
pos 2, y_bottom : sysfont 0 : color
return
*start_apache
exist ""+PATH_NGINX_FOLDER+"\\nginx.exe"
if strsize == -1 : return
EnableWindow hButton_start_apache, 0
EnableWindow hButton_stop_apache, 1
// apache起動
dirCur = _dir_cur_
chdir ""+PATH_NGINX_FOLDER
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, ""+PATH_NGINX_FOLDER+"\\nginx.exe" ; コマンドプロンプト非表示で実行(pipeexecだけど監視しない)
chdir dirCur
// PHP-FPM起動
dirCur = _dir_cur_
chdir ""+PATH_PHP_FOLDER
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, ""+PATH_PHP_FOLDER+"\\php-cgi.exe -b 127.0.0.1:9000" ; コマンドプロンプト非表示で実行(pipeexecだけど監視しない)
chdir dirCur
return
*stop_apache
exist ""+PATH_NGINX_FOLDER+"\\nginx.exe"
if strsize == -1 : return
EnableWindow hButton_start_apache, 1
EnableWindow hButton_stop_apache, 0
// apache終了
dirCur = _dir_cur_
chdir ""+PATH_NGINX_FOLDER
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, ""+PATH_NGINX_FOLDER+"\\nginx.exe -s quit" ; コマンドプロンプト非表示で実行(pipeexecだけど監視しない)
chdir dirCur
// PHP-FPM終了
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, "Taskkill /im php-cgi.exe /f" ; コマンドプロンプト非表示で実行(pipeexecだけど監視しない)
return
*buttonEnabler_apache_controller
; in isRunHttpdExe
if created_apache_controller == 0 : return
EnableWindow hButton_start_apache, isRunHttpdExe==0
EnableWindow hButton_stop_apache, isRunHttpdExe==1
return
//--------------------------------------
// localhostリンク - dish.js実行準備ができたか監視。OKならURLやフォルダへのリンクを表示する
// ・コントロール作成
// ・ローカルIP版リンク作成
//--------------------------------------
*show_localhost_link
if showed_localhost_link : return
showed_localhost_link = 1
// ローカルIPアドレス取得
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, "ipconfig"
do : wait 1 : pipeget pipe_ln : until stat==0
localIP = ""
result = submatch(pipe_buf,"^Wireless Lan adapter Wi-Fi.*?:\n\n([\\s\\S]+?)\n\n") ; wi-fi接続の項目を優先する
if result == "" : result = submatch(pipe_buf,"^Wireless Lan adapter ワイヤレス ネットワーク接続.*?:\n\n([\\s\\S]+?)\n\n") ; 可能性を考慮
if result == "" : result = submatch(pipe_buf,"^Wireless Lan adapter Wireless Network Connection.*?:\n\n([\\s\\S]+?)\n\n") ; 可能性を考慮
if result != "" : localIP = submatch(result, "IPv4.*?(192\\.168\\.\\d+\\.\\d+)") ; wi-fi項目から
if localIP == "" : localIP = submatch(pipe_buf, "IPv4.*?(192\\.168\\.\\d+\\.\\d+)") ; 全体から
//----------------
// コントロール作成
//----------------
sysfont 0
mes ""
g_cy = ginfo_cy
mes "作成したHTMLをブラウザで開く" : g_mesx = ginfo_mesx
font "MS Pゴシック", 16, 1+4 : pos ginfo_sx : mes "http://127.0.0.1/"+ getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName, 1 : pos 5 : sysfont 0
winobj "static", "http://127.0.0.1/"+ getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName, , $50000000 | $100, limit(ginfo_mesx,0,395), ginfo_mesy
hStatic_localhost = objinfo_hwnd(stat)
pos 2 : mes ""
mes "エクスプローラでフォルダを開く"
font "MS Pゴシック", 16, 1+4 : pos ginfo_sx : mes htdocsFolderPath+"\\"+ getpath(_ScFileName_@ezLocalDishJs, 1+8), 1 : pos 5 : sysfont 0
winobj "static", htdocsFolderPath+"\\"+ getpath(_ScFileName_@ezLocalDishJs, 1+8), , $50000000 | $100, limit(ginfo_mesx,0,395), ginfo_mesy
hStatic_htmlFolder = objinfo_hwnd(stat)
g_cy2 = ginfo_cy
pos ,g_cy+1
font "MS Pゴシック", 16, 1+4 : pos ginfo_sx : mes "!画面サイズ", 1 : pos 5 + g_mesx + 5 : sysfont 0
winobj "static", "!画面サイズ", , $50000000 | $100, limit(ginfo_mesx,0,395-g_mesx), ginfo_mesy
hStatic_noticeNonIni = objinfo_hwnd(stat)
ShowWindow hStatic_noticeNonIni, (notice_nonIni != 0)
//----------------
// ローカルIP版リンク作成
//----------------
if localIP != "" {
sysfont 17
pos 410, g_cy
mes "スマホでローカルサーバにアクセス"
pos , ginfo_cy + 10
// QRコード作成
if ( varptr(QRcode_encodeString) != 0 ){
// QRコード化したいURLをいれる
url = "http://" + localIP + "/" + getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName
b = 3 // 倍率
ox = ginfo_cx // オフセットX
oy = ginfo_cy // オフセットX
QRcode_encodeString url, 0, 3, 3, 1
qrcode = stat
dupptr res, qrcode, 12, 4
size = res.1
dupptr data, res.2, size*size, 2
// QRコードの描画
color : redraw 0
i = 0 : x = 0
repeat size
x = cnt
repeat size
// クロだった場合
if peek(data,i)&1{
boxf cnt*b+ox, x*b+oy, cnt*b+b+ox, x*b+b+oy
}
i++
loop
loop
redraw 1
// 終わったら解放
QRcode_free qrcode
pos , ginfo_cy + b*size + 8
sysfont 17 : color 160,160,160
mes "↑ http://" + localIP + "/"+ getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName
color
// QRコードを作成するdllがないのでstaticリンクを作成
}else {
font "MS Pゴシック", 16, 1+4 : pos ginfo_sx : mes "http://" + localIP + "/" + getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName, 1 : pos 410 : sysfont 0
winobj "static", "http://" + localIP + "/"+ getpath(_ScFileName_@ezLocalDishJs, 1+8) + "/" + createdHtmlName, , $50000001 | $100, limit(ginfo_mesx,0,400), ginfo_mesy
hStatic_localip = objinfo_hwnd(stat)
sysfont 17 : color 160,160,160 : pos 410, ginfo_cy+10
mes "・", 1 : mes "「qrcodelib.dll」をHSP3インストールフォルダか\nスクリプトと同じフォルダに置けば\nQRコードで表示することができます。"
color
}
} // ローカルIP版リンク作成
sysfont 17
pos 2, g_cy2
mes ""
mes ""
mes "※",1
mes "レンタルサーバを借りて、作成したファイルをアップロードすれば"
mes "ウェブ上で同じように動作させることができます。"
// コントロールのフォント,カーソル設定変更
font "MS Pゴシック", 16, 1+4
mref BMSCR, 67
sendmsg hStatic_localhost, $30, BMSCR.38
sendmsg hStatic_htmlFolder, $30, BMSCR.38
sendmsg hStatic_noticeNonIni, $30, BMSCR.38
if hStatic_localip : sendmsg hStatic_localip, $30, BMSCR.38
hCursor = LoadCursor(0, 32649)
SetClassLong hStatic_localhost, -12, hCursor
SetClassLong hStatic_htmlFolder, -12, hCursor
SetClassLong hStatic_noticeNonIni, -12, hCursor
if hStatic_localip : SetClassLong hStatic_localip, -12, hCursor
gsel ginfo_sel, 2
gsel ginfo_sel, 1
return
//--------------------------------------
// oncmd
//--------------------------------------
*ctlcolorstatic
if lparam == 0 : return
if hStatic_localhost == lparam || hStatic_htmlFolder == lparam || hStatic_localip == lparam {
SetTextColor wparam, 0 | 0 << 8 | 255 << 16
SetBkMode wparam, 1
if hBrush == 0 : hBrush = GetSysColorBrush(5)
return hBrush
}
if hStatic_noticeNonIni == lparam {
SetTextColor wparam, 255 | 0 << 8 | 0 << 16
SetBkMode wparam, 1
if hBrush == 0 : hBrush = GetSysColorBrush(5)
return hBrush
}
return
*command
if lparam == 0 : return
if hStatic_localhost == lparam || hStatic_htmlFolder == lparam || hStatic_localip == lparam {
sdim text_static, 512
Sendmsg lparam, 0xD /*WM_GETTEXT*/, 512, varptr(text_static)
exec text_static, 16
return
}
if hStatic_noticeNonIni == lparam {
dialog "スクリプトに画面サイズ変更処理を検出しました。\n画面サイズを変更するには hsp3dish.ini が必要になります。\n\nウィンドウ右上の 「+」ボタン>「hsp3dish.ini編集」ボタン から iniファイルの作成と編集が可能です。\n\n作成後、HSP3Dish helper の「変換」を再度実行してください。", 0, "ezlocal-dish-js"
return
}
return
//--------------------------------------
// onexit
//--------------------------------------
*quit
// もし.ezjsが作ってあれば削除する
repeat length(dhjsFileName_paths)-1, 1
exist dhjsFileName_paths(cnt)
if strsize != -1 : delete dhjsFileName_paths(cnt)
loop
// ini
exist _dir_cur_ + "\\hsp3dish.ini"
if strsize != -1 {
notesel iniFileSource : noteload _dir_cur_ + "\\hsp3dish.ini"
// ヘッダ
if instr(iniFileSource, 0, "; ezlocal-dish-js settings") == -1 {
iniFileSource += "\n\n; ezlocal-dish-js settings"
}
// sx, sy
if match(iniFileSource, "^\\s*sx\\s*=") == "" {
ini_wx = submatch(iniFileSource, "^\\s*wx\\s*=\\s*(\\d+)")
if ini_wx != "" : ini_sx = ini_wx : else : ini_sx = "320"
iniFileSource += "\nsx="+ini_sx
}
if match(iniFileSource, "^\\s*sy\\s*=") == "" {
ini_wy = submatch(iniFileSource, "^\\s*wy\\s*=\\s*(\\d+)")
if ini_wy != "" : ini_sy = ini_wy : else : ini_sy = "480"
iniFileSource += "\nsy="+ini_sy
}
// chkbox_ezLocalAdjust
if match(iniFileSource, "(^\\s*chkbox_ezLocalAdjust\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_ezLocalAdjust\\s*=\\s*)(\\d+)", "$1"+chkbox_ezLocalAdjust)
}else {
iniFileSource += "\nchkbox_ezLocalAdjust="+chkbox_ezLocalAdjust
}
// chkbox_landscapeFit
if match(iniFileSource, "(^\\s*chkbox_landscapeFit\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_landscapeFit\\s*=\\s*)(\\d+)", "$1"+chkbox_landscapeFit)
}else {
iniFileSource += "\nchkbox_landscapeFit="+chkbox_landscapeFit
}
// chkbox_saveToBrowser
if match(iniFileSource, "(^\\s*chkbox_saveToBrowser\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*chkbox_saveToBrowser\\s*=\\s*)(\\d+)", "$1"+chkbox_saveToBrowser)
}else {
iniFileSource += "\nchkbox_saveToBrowser="+chkbox_saveToBrowser
}
// button_openOptions
if match(iniFileSource, "(^\\s*button_openOptions\\s*=\\s*)(\\d+)") != "" {
iniFileSource = replace(iniFileSource, "(^\\s*button_openOptions\\s*=\\s*)(\\d+)", "$1"+button_openOptions)
}else {
iniFileSource += "\nbutton_openOptions="+button_openOptions
}
notesave _dir_cur_ + "\\hsp3dish.ini" : noteunsel
}
end
end
stop
//--------------------------------------
// HTMLをezlocal-dish-js
//--------------------------------------
#deffunc local HtmlEzLocalAdjuster str _htmlFileName_path
exist _htmlFileName_path
if strsize == -1 : return
// hsp3dish.ini - load
iniFileSource = ""
exist _dir_cur_ + "\\hsp3dish.ini"
if strsize != -1 : notesel iniFileSource : noteload _dir_cur_ + "\\hsp3dish.ini" : noteunsel
// HTMLソース - load
notesel htmlSource : noteload _htmlFileName_path
if (hspstat & $20000) == 0 {
nkfcnv@ htmlSource, htmlSource, "Ws", , strlen(htmlSource)*2
}
// sx, sy
envHsp_sx = submatch(iniFileSource, "^\\s*sx\\s*=\\s*(.+?)[\\r\\n]")
if envHsp_sx != "" {
if envHsp_sx == str(int(envHsp_sx)) { ; 数値
htmlSource = replace(htmlSource, "(ENV.HSP_SX\\s*=\\s*\")(\\d+)(\")", "$1"+envHsp_sx+"$3")
}else{ ; 文字列
htmlSource = replace(htmlSource, "(ENV.HSP_SX\\s*=\\s*)(\"\\d+\")", "$1"+envHsp_sx)
}
}
envHsp_sy = submatch(iniFileSource, "^\\s*sy\\s*=\\s*(.+?)[\\r\\n]")
if envHsp_sy != "" {
if envHsp_sy == str(int(envHsp_sy)) { ; 数値
htmlSource = replace(htmlSource, "(ENV.HSP_SY\\s*=\\s*\")(\\d+)(\")", "$1"+envHsp_sy+"$3")
}else { ; 文字列
htmlSource = replace(htmlSource, "(ENV.HSP_SY\\s*=\\s*)(\"\\d+\")", "$1"+envHsp_sy)
}
}
// autoscale
envHsp_autoscale = submatch(iniFileSource, "^\\s*autoscale\\s*=\\s*(\\d+)")
if envHsp_autoscale != "" {
htmlSource = replace(htmlSource, "(ENV.HSP_AUTOSCALE\\s*=\\s*\")(\\d+)(\")", "$1"+envHsp_autoscale+"$3")
}
// 外周枠線
if chkbox_ezLocalAdjust {
if match(iniFileSource, "^\\s*noAdj_border\\s*=\\s*1") == "" {
htmlSource = replace(htmlSource, "(div\\.emscripten_border \\{ border: 1px solid black; \\})", "/*$1*/ /* ezlocal-dish-js */")
}
}
// 非表示コントロール(controls,status)
if chkbox_ezLocalAdjust {
if match(iniFileSource, "^\\s*noAdj_controls\\s*=\\s*1") == "" {
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(var\\s+spinnerElement\\s+=\\s+document\\.getElementById\\('spinner'\\);.*?(?:\\r\\n|\\n|\\r))", "$1$2$3$2document.getElementById('controls').style.display = \"none\"; // ezlocal-dish-js$1")
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(if\\s*\\(\\!text\\)\\s*spinnerElement\\.style\\.display\\s*=\\s*'none';.*(?:\\r\\n|\\n|\\r))", "$1$2$3$2if (!text) statusElement.style.display = 'none'; // ezlocal-dish-js$1")
}
}
// システムメッセージ
if chkbox_ezLocalAdjust {
if match(iniFileSource, "^\\s*noAdj_systembox\\s*=\\s*1") == "" {
htmlSource = replace(htmlSource, "(#output\\s+\\{)(\\r\\n|\\n|\\r)(\\s*width:\\s*)(\\d+)(%;)", "$1$2$398$5 /* ezlocal-dish-js */")
; デバッグモードかでシステムウィンドウの開き具合を調整
text_InOrOutDebugMode = "if (text.includes('#Error')) "
hWnd_DishHelper = SearchWindow(0,, "hspwnd0", "^HSP3Dish helper")
if hWnd_DishHelper != 0 {
hCheck_DebugOut = SearchWindow(hWnd_DishHelper,, "Button", "デバッグ情報を出力する") ; checkbox
if hCheck_DebugOut != 0 {
sendmsg hCheck_DebugOut, $00F0/*BM_GETCHECK*/, 0, 0
if (stat != 0) : text_InOrOutDebugMode = ""
}
}
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(element\\.scrollTop\\s*=\\s*element\\.scrollHeight;.*?(?:\\r\\n|\\n|\\r))", "$1$2$3$2"+text_InOrOutDebugMode+"element.style.display = \"\"; // ezlocal-dish-js$1")
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(var\\s+spinnerElement\\s+=\\s+document\\.getElementById\\('spinner'\\);.*?(?:\\r\\n|\\n|\\r))", "$1$2$3$2document.getElementById('output').style.display = \"none\"; // ezlocal-dish-js$1")
}
}
// データ保存
if chkbox_saveToBrowser {
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(ENV\\.HSP_LIMIT_STEP\\s*=.*(?:\\r\\n|\\n|\\r))", "$1$2$3$2ENV.HSP_SYNC_DIR = \"/save\"; // ezlocal-dish-js$1")
}
// スマホ表示
if chkbox_ezLocalAdjust {
if match(iniFileSource, "^\\s*noAdj_mobile\\s*=\\s*1") == "" {
envHsp_wx = submatch(iniFileSource, "^\\s*wx\\s*=\\s*(.+?)[\\r\\n]")
envHsp_wy = submatch(iniFileSource, "^\\s*wy\\s*=\\s*(.+?)[\\r\\n]")
if chkbox_landscapeFit == 0 || (int(envHsp_wx) <= int(envHsp_sy)) {
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(ENV\\.HSP_LIMIT_STEP\\s*=.*(?:\\r\\n|\\n|\\r))", "$1$2$3$2if (navigator.userAgent.match(/iPhone|Android.+Mobile/)) { // ezlocal-dish-js$1$2\tENV.HSP_SX = String(window.innerWidth);$1$2\tENV.HSP_SY = String(window.innerHeight);$1$2}$1")
}else {
htmlSource = replace(htmlSource, "(\\r\\n|\\n|\\r)(\\s*)(ENV\\.HSP_LIMIT_STEP\\s*=.*(?:\\r\\n|\\n|\\r))", "$1$2$3$2if (navigator.userAgent.match(/iPhone|Android.+Mobile/)) { // ezlocal-dish-js$1$2\tif (navigator.userAgent.match(/iPhone/)) {$1$2\t\tconst meta = document.createElement('meta');$1$2\t\tmeta.name = 'viewport';$1$2\t\tmeta.content = 'width='+ window.innerWidth +', viewport-fit=cover';$1$2\t\tdocument.getElementsByTagName('head')[0].appendChild(meta);$1$2\t}$1$2\tconst newDiv = document.createElement('div');$1$2\tnewDiv.style.width = '100vw';$1$2\tnewDiv.style.height = '50vh';$1$2\tconst referenceNode = document.getElementById('canvas');$1$2\treferenceNode.parentNode.insertBefore(newDiv, referenceNode);$1$2\tconst cloneDiv = newDiv.cloneNode(true);$1$2\tcloneDiv.id = 'oridev';$1$2\tif( !navigator.userAgent.match(/iPhone.+\\(KHTML, like Gecko\\) Version\\/.+Mobile.+Safari/) ){$1$2\t\tcloneDiv.style.fontSize = '3em';$1$2\t\tcloneDiv.style.textAlign = 'center';$1$2\t\tcloneDiv.innerHTML = '
- Fit Landscape -
⇅スクロールしてURLバーが消えたら
📱 → 📱
デバイスを回転させてください';$1$2\t}$1$2\tdocument.body.appendChild(cloneDiv);$1$2\tconst loovh = document.getElementById('oridev').clientHeight * 2;$1$2\tfunction ScrollCenterCanvas() {$1$2\t\tsetTimeout(() => {$1$2\t\t\tdocument.getElementById('canvas').scrollIntoView({ behavior: 'smooth', block: 'center' });$1$2\t\t}, 500);$1$2\t}$1$2\twindow.addEventListener('orientationchange', ScrollCenterCanvas);$1$2\tScrollCenterCanvas();$1$2\tif (navigator.userAgent.match(/iPhone/)) {$1$2\t\tENV.HSP_SX = String(window.innerWidth);$1$2\t\tENV.HSP_SY = String(window.innerWidth*screen.width/screen.height);$1$2\t}else {$1$2\t\tconst statusNavigationBar = window.innerWidth * screen.height / screen.width - loovh;$1$2\t\tconst newDiv_s = document.createElement('div');$1$2\t\tnewDiv_s.id = 'oridev_s';$1$2\t\tnewDiv_s.style.height = '100svh';$1$2\t\tdocument.body.appendChild(newDiv_s);$1$2\t\tconst urlBar = (loovh - newDiv_s.clientHeight);$1$2\t\tnewDiv_s.remove();$1$2\t\tlet _SY = window.innerWidth * screen.width / screen.height - statusNavigationBar * screen.width / screen.height / window.devicePixelRatio;$1$2\t\tif (statusNavigationBar > urlBar * 1.25)$1$2\t\t\t_SY += urlBar / window.devicePixelRatio;$1$2\t\tENV.HSP_SX = String(window.innerWidth);$1$2\t\tENV.HSP_SY = String(_SY);$1$2\t}$1$2}$1")
}
}
}
if (hspstat & $20000) == 0 {
nkfcnv@ htmlSource, htmlSource, "Sw", , strlen(htmlSource)*2
}
notesave _htmlFileName_path : noteunsel
return
//--------------------------------------
// ファイルダウンロード
//--------------------------------------
#deffunc local Downloader str _loadUrl, str _folderPath_downloads, label messageLabel
mref mrefRefstr, 65
// 最初に 0.0% 報告
mrefRefstr = strf("% 4.1f %%",0.0)
gosub messageLabel
// ファイルサイズ取得
fileSize = 0
neturl@ getpath(_loadUrl,32)
netfileinfo@ p, getpath(_loadUrl,8)
if vartype(p) == 4 : return "" ; ネット接続できなかった
if stat == 0 : fileSize = int(submatch(p,"Content-Length: (\\d*)\n"))
if fileSize == 0 : fileSize = 1 ; 0割りを防ぐため
dirCur = _dir_cur_
chdir _folderPath_downloads
// ランタイム(cabファイル)ダウンロード
netrequest@ getpath(_loadUrl,8)
do
wait 10 : netexec@ res
exist getpath(_loadUrl,8)
mrefRefstr = strf("% 4.1f %%",limitf(1.0*strsize/(1.0*fileSize/100),0.0,100.0))
gosub messageLabel
until res ; ダウンロードループ
chdir dirCur
;mrefRefstr = strf("% 4.1f %%",100.0)
;gosub messageLabel
return _folderPath_downloads + "\\" + getpath(_loadUrl,8)
//--------------------------------------
// zipファイル展開
//--------------------------------------
#deffunc local Unzipper str _zipFilePath, str _folderPath_unzip, label messageLabel
mref mrefRefstr, 65
// 最初に 0.0% 報告
mrefRefstr = strf("% 4.1f %%",0.0)
gosub messageLabel
// 展開後ファイル数を取得
cmd = "cmd /c powershell \"add-type -assemblyname system.io.compression.filesystem;[io.compression.zipfile]::openread('"+_zipFilePath+"').entries | ft length\""
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, cmd
do : wait 1 : pipeget pipe_ln : until stat==0
index = 0
getstr dummy, pipe_buf, index : index += strsize
getstr dummy, pipe_buf, index : index += strsize
getstr dummy, pipe_buf, index : index += strsize
pipe_buf = strmid(pipe_buf, index, strlen(pipe_buf))
strrep pipe_buf, " ", ""
dirStrLength = strlen(pipe_buf)
// 展開後のトップのフォルダ名を取得
cmd = "cmd /c powershell \"add-type -assemblyname system.io.compression.filesystem;[io.compression.zipfile]::openread('"+_zipFilePath+"').entries[0] | ft -a fullname\""
pipe_buf = "" : pipe_ln = ""
pipeexec pipe_buf, cmd
do : wait 1 : pipeget pipe_ln : until stat==0
index = 0
getstr dummy, pipe_buf, index : index += strsize
getstr dummy, pipe_buf, index : index += strsize
getstr dummy, pipe_buf, index : index += strsize
pipe_buf = strmid(pipe_buf, index, strlen(pipe_buf))
pipe_buf = strtrim(pipe_buf, 1)
topFolderName_unzip = submatch(pipe_buf,"^(.+?)/")
pathSupport = ""
if strlen(_folderPath_unzip) == 2 : pathSupport = "\\" ; ドライブ直下C:\とかだとC:で来ているので必要なとき足す
// 展開するzipがトップフォルダ1つだけ存在するものかどうか確認
checkOneTopFolder = match(pipe_buf, "^(?!"+topFolderName_unzip+"/).+$")
if peek(checkOneTopFolder) == 0x0D : poke checkOneTopFolder, 0, 0 ; 何故か 0x0D だけ吸ってくるみたい(?)なので
if peek(checkOneTopFolder) == 0x0A : poke checkOneTopFolder, 0, 0
if topFolderName_unzip == "" || checkOneTopFolder != "" {
// 違った場合tempフォルダを作ってそこに展開する
pathSupport = "\\temp_ezlocal"
topFolderName_unzip = "temp_ezlocal"
}
// 実際に展開
pipe_buf = "" : pipe_ln = ""
cmd = "cmd /c powershell \"Expand-Archive -Path '"+_zipFilePath+"' -DestinationPath '"+_folderPath_unzip + pathSupport+"'\" -Force"
pipeexec pipe_buf, cmd
// 展開開始されるまで待機
repeat
wait 75
PathIsDirectory _folderPath_unzip+"\\"+topFolderName_unzip
if stat != 0 : break
loop
// 展開を確認してからchdir
dirCur = _dir_cur_
chdir _folderPath_unzip + "\\" + topFolderName_unzip
dirlist2h 4
do : wait 100
dirlist2 d2size, "*", 1
mrefRefstr = strf("% 4.1f %%",limitf(1.0*d2size/(1.0*dirStrLength/100),0.0,100.0))
gosub messageLabel
pipeget pipe_ln
until stat==0
chdir dirCur
;mrefRefstr = strf("% 4.1f %%",100.0)
;gosub messageLabel
return _folderPath_unzip + "\\" + topFolderName_unzip
//--------------------------------------
// 特殊システムフォルダパス取得
//--------------------------------------
#uselib "SHELL32.DLL"
#func SHGetKnownFolderPath "SHGetKnownFolderPath" int,int,int,int
#uselib "OLE32.dll"
#func IIDFromString "IIDFromString" sptr,sptr
#func CoTaskMemFree "CoTaskMemFree" int
#defcfunc local GetKnownFolderPath str guid
sdim psW_guid,78
dim piid_guid,4
cnvstow psW_guid, guid
IIDFromString varptr(psW_guid), varptr(piid_guid)
SHGetKnownFolderPath varptr(piid_guid),0,0,varptr(pFolderW)
c=0
repeat 1024
dupptr nullnull, pFolderW + cnt, 2, 4
if nullnull = 0 : c = cnt+2 : break
loop
if c = 0 : return ""
dupptr folderW, pFolderW, c, 2
folder = cnvwtos(folderW)
CoTaskMemFree pFolderW
return folder
//--------------------------------------
// サブディレクトリ含めたフォルダ削除
//--------------------------------------
#uselib "shell32"
#func SHFileOperation "SHFileOperationA" int
#deffunc local DeleteFolder str _dir
sdim pFrom, 260
pFrom = _dir
dim SHFILEOPSTRUCT, 8
SHFILEOPSTRUCT.0 = hWnd
SHFILEOPSTRUCT.1 = 0x0003 // FO_DELETE
SHFILEOPSTRUCT.2 = varptr( pFrom )
SHFILEOPSTRUCT.3 = 0
SHFILEOPSTRUCT.4 = 0x0114 // FOF_SIMPLEPROGRESS | FOF_NOCONFIRMATION | FOF_SILENT
SHFileOperation varptr( SHFILEOPSTRUCT )
return stat
//--------------------------------------
// ウィンドウ検索
//--------------------------------------
#uselib "user32.dll"
#cfunc FindWindowEx "FindWindowExA" sptr,sptr,sptr,sptr
#func GetWindowText "GetWindowTextA" sptr,sptr,sptr
#defcfunc local SearchWindow int _oyaHwnd, int _childHwnd, str _sClass, str _mTitle
sClass = _sClass : if sClass == "" : sClass = 0
sdim text, 256
childHwnd = _childHwnd
repeat
childHwnd = FindWindowEx(_oyaHwnd, childHwnd, sClass, 0)
if childHwnd == 0 : break
if _mTitle == "" : break
GetWindowText childHwnd, varptr(text), 256
if match(text, _mTitle) != "" : break
loop
mref mrefRefstr, 65
if childHwnd != "" : mrefRefstr = text : else : mrefRefstr = ""
return childHwnd
//--------------------------------------
// プロセスが実行中か確認
// - 「プロセスとモジュールを取得メモ」
// - HSPメモ帳 (Hiro さん)
// - https://blog.goo.ne.jp/hiro239415/e/8146d7c0f10246f455b25a2b6e3728f1
//--------------------------------------
#uselib "kernel32.dll"
#func CreateToolhelp32Snapshot "CreateToolhelp32Snapshot" int,int
#func Process32First "Process32First" int , sptr
#func Process32Next "Process32Next" int , sptr
#func CloseHandle "CloseHandle" int
#defcfunc local isRunProcess str processName
dim er
sdim lbdata , 1024
sdim data , 260
dim hpsnap
dim p_entry, 74
dim p_id , 64
CreateToolhelp32Snapshot 0x0f , 0
hpsnap = stat
if hpsnap==-1 : return 0
dim p_id , 64
lbdata="" : notesel lbdata
p_entry(0) = 296
Process32First hpsnap , varptr(p_entry)
er = stat
repeat -1
if er == 0 : break
getstr data , p_entry , 36 , '\0'
noteadd data , -1
p_id(cnt) = p_entry(2)
Process32Next hpsnap , varptr(p_entry)
er = stat
loop
#if __hspver__ < 13571 ; HSP3.5beta3未満(本当は3.5beta2未満にしたいがアーカイブ見つからず)
_noteg = "" : er = 0
repeat notemax
noteget _noteg, cnt : if _noteg == processName : er = 1 : break
loop
#else
er = notefind(processName) != -1
#endif
noteunsel
CloseHandle hpsnap
return er
//--------------------------------------
// グループボックス
//--------------------------------------
#uselib "user32.dll"
#func GetWindowLong "GetWindowLongA" int,int
#func SetWindowLong "SetWindowLongA" int,int,int
#deffunc local grpbox str p1, int p2, int p3
x = p2 : y = p3
mref bmscr,67
ox = bmscr.29 : oy = bmscr.30 : py = bmscr.31 //object size
if x = 0 : x = ox
if y = 0 : y = oy
chk_dummy = 0
objsize x,y, py
chkbox p1, chk_dummy
st = stat
sendmsg objinfo(st,2), 0x00F4/*BM_SETSTYLE*/, 0x0007/*BS_GROUPBOX*/, 1
GetWindowLong objinfo(st,2), 0xFFFFFFEC/*GWL_EXSTYLE*/
SetWindowLong objinfo(st,2), 0xFFFFFFEC/*GWL_EXSTYLE*/, stat | 0x00000020/*WS_EX_TRANSPARENT*/
objsize ox,oy,py ;元に戻す
return st
//--------------------------------------
// Tooltip
//--------------------------------------
#uselib "user32"
#func GetClientRect "GetClientRect" int, int
#deffunc local SetTooltip int hObj, str _text
if tooltip_inited == 0 {
// 初期化
gcxy = ginfo_cx, ginfo_cy
winobj "tooltips_class32", "", 0, 3
htooltip = objinfo_hwnd(stat)
dim tooltipRECT, 4 : tooltipRECT = 3,3,3,3
SendMsg htooltip, $00D3/*TTM_SETMARGIN*/, 0, varptr(tooltipRECT) ; マージン
SendMsg htooltip, $0418/*TTM_SETMAXTIPWIDTH*/, 0, 640 ; tipwidth
SendMsg htooltip, $0403/*TTM_SETDELAYTIME*/, 2, 30000 ; 表示時間
dim TOOLINFO, 11
pos gcxy(0), gcxy(1)
}
text = _text
GetClientRect hObj, varptr(tooltipRECT)
TOOLINFO(0) = 40, $10, hObj, 0, tooltipRECT.0, tooltipRECT.1, tooltipRECT.2, tooltipRECT.3, 0, varptr(text)
SendMsg htooltip, $0404/*TTM_ADDTOOL*/, 0, varptr(TOOLINFO)
return
//--------------------------------------
// mod_MSZip : Cabinet.dllを使用した圧縮解凍モジュール
// - HSPメモ帳 (Hiro さん)
// - https://blog.goo.ne.jp/hiro239415/e/fe657bd57b6d2de0c4855c0578452dd9
// - qrcodelib.dllが無い場合出力するために使わせて頂きます。
//--------------------------------------
#uselib "kernel32.dll"
#func GetLastError "GetLastError"
#uselib "Cabinet.dll"
#func CreateDecompressor "CreateDecompressor" int,int,var
#func CloseDecompressor "CloseDecompressor" int
#func Decompress "Decompress" int,var,int,int,int,var
#uselib "Crypt32.dll"
#func CryptStringToBinary "CryptStringToBinaryA" sptr,int,int,int,var,int,int
hcomp=0
#deffunc local MSZipDecomp int msz_size, var msz_src, var msz_dst
ds = 0
if ( msz_size ){ ss = msz_size } else { ss = varsize(msz_src) }
CreateDecompressor 2, 0, hComp
if ( stat ){
Decompress hComp, msz_src, ss, 0, 0, ds
GetLastError
if ( stat == 122 ){
sdim buf, ds
Decompress hComp, msz_src, ss, varptr(buf), ds, ds
if ( stat ){ sdim msz_dst, ds : memcpy msz_dst, buf, ds }
else { ds = 0 }
buf = 0
}
CloseDecompressor hComp
}
return ds
#deffunc local MSZipFromCode str msz_src, var msz_dst
CryptStringToBinary msz_src, 0, 1, 0, ds, 0, 0
if ( stat == 0 ){ return 0 }
sdim d, ds
CryptStringToBinary msz_src, 0, 1, varptr(d), ds, 0, 0
if ( stat ){ MSZipDecomp ds, d, msz_dst }
d = 0
return ds
/*
- 使用ライブラリ
--------------------------------------------------------------------------------
qrcodelib.dll _ Copyright (C) 2006-2018 Kentaro Fukuchi
QRコードを生成するための高速かつコンパクトなライブラリ
・ライセンス :GNU Lesser General Public License (LGPL)
・バイナリ頒布先: http://code.google.com/p/qrencode-win32/
・ソースコード : https://github.com/fukuchi/libqrencode
・HSP3コード参考: https://codetter.com/?p=525
--------------------------------------------------------------------------------
Copyright (C) 2006-2018 Kentaro Fukuchi
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either version 2.1 of the License, or any later version.
This library 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 Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
----------------------------------------------------------------------
GNU LESSER GENERAL PUBLIC LICENSE
Version 2.1, February 1999
Copyright (C) 1991, 1999 Free Software Foundation, Inc.
51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.
[This is the first released version of the Lesser GPL. It also counts
as the successor of the GNU Library Public License, version 2, hence
the version number 2.1.]
Preamble
The licenses for most software are designed to take away your
freedom to share and change it. By contrast, the GNU General Public
Licenses are intended to guarantee your freedom to share and change
free software--to make sure the software is free for all its users.
This license, the Lesser General Public License, applies to some
specially designated software packages--typically libraries--of the
Free Software Foundation and other authors who decide to use it. You
can use it too, but we suggest you first think carefully about whether
this license or the ordinary General Public License is the better
strategy to use in any particular case, based on the explanations
below.
When we speak of free software, we are referring to freedom of use,
not price. Our General Public Licenses are designed to make sure that
you have the freedom to distribute copies of free software (and charge
for this service if you wish); that you receive source code or can get
it if you want it; that you can change the software and use pieces of
it in new free programs; and that you are informed that you can do
these things.
To protect your rights, we need to make restrictions that forbid
distributors to deny you these rights or to ask you to surrender these
rights. These restrictions translate to certain responsibilities for
you if you distribute copies of the library or if you modify it.
For example, if you distribute copies of the library, whether gratis
or for a fee, you must give the recipients all the rights that we gave
you. You must make sure that they, too, receive or can get the source
code. If you link other code with the library, you must provide
complete object files to the recipients, so that they can relink them
with the library after making changes to the library and recompiling
it. And you must show them these terms so they know their rights.
We protect your rights with a two-step method: (1) we copyright the
library, and (2) we offer you this license, which gives you legal
permission to copy, distribute and/or modify the library.
To protect each distributor, we want to make it very clear that
there is no warranty for the free library. Also, if the library is
modified by someone else and passed on, the recipients should know
that what they have is not the original version, so that the original
author's reputation will not be affected by problems that might be
introduced by others.
Finally, software patents pose a constant threat to the existence of
any free program. We wish to make sure that a company cannot
effectively restrict the users of a free program by obtaining a
restrictive license from a patent holder. Therefore, we insist that
any patent license obtained for a version of the library must be
consistent with the full freedom of use specified in this license.
Most GNU software, including some libraries, is covered by the
ordinary GNU General Public License. This license, the GNU Lesser
General Public License, applies to certain designated libraries, and
is quite different from the ordinary General Public License. We use
this license for certain libraries in order to permit linking those
libraries into non-free programs.
When a program is linked with a library, whether statically or using
a shared library, the combination of the two is legally speaking a
combined work, a derivative of the original library. The ordinary
General Public License therefore permits such linking only if the
entire combination fits its criteria of freedom. The Lesser General
Public License permits more lax criteria for linking other code with
the library.
We call this license the "Lesser" General Public License because it
does Less to protect the user's freedom than the ordinary General
Public License. It also provides other free software developers Less
of an advantage over competing non-free programs. These disadvantages
are the reason we use the ordinary General Public License for many
libraries. However, the Lesser license provides advantages in certain
special circumstances.
For example, on rare occasions, there may be a special need to
encourage the widest possible use of a certain library, so that it
becomes a de-facto standard. To achieve this, non-free programs must
be allowed to use the library. A more frequent case is that a free
library does the same job as widely used non-free libraries. In this
case, there is little to gain by limiting the free library to free
software only, so we use the Lesser General Public License.
In other cases, permission to use a particular library in non-free
programs enables a greater number of people to use a large body of
free software. For example, permission to use the GNU C Library in
non-free programs enables many more people to use the whole GNU
operating system, as well as its variant, the GNU/Linux operating
system.
Although the Lesser General Public License is Less protective of the
users' freedom, it does ensure that the user of a program that is
linked with the Library has the freedom and the wherewithal to run
that program using a modified version of the Library.
The precise terms and conditions for copying, distribution and
modification follow. Pay close attention to the difference between a
"work based on the library" and a "work that uses the library". The
former contains code derived from the library, whereas the latter must
be combined with the library in order to run.
GNU LESSER GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License Agreement applies to any software library or other
program which contains a notice placed by the copyright holder or
other authorized party saying it may be distributed under the terms of
this Lesser General Public License (also called "this License").
Each licensee is addressed as "you".
A "library" means a collection of software functions and/or data
prepared so as to be conveniently linked with application programs
(which use some of those functions and data) to form executables.
The "Library", below, refers to any such software library or work
which has been distributed under these terms. A "work based on the
Library" means either the Library or any derivative work under
copyright law: that is to say, a work containing the Library or a
portion of it, either verbatim or with modifications and/or translated
straightforwardly into another language. (Hereinafter, translation is
included without limitation in the term "modification".)
"Source code" for a work means the preferred form of the work for
making modifications to it. For a library, complete source code means
all the source code for all modules it contains, plus any associated
interface definition files, plus the scripts used to control
compilation and installation of the library.
Activities other than copying, distribution and modification are not
covered by this License; they are outside its scope. The act of
running a program using the Library is not restricted, and output from
such a program is covered only if its contents constitute a work based
on the Library (independent of the use of the Library in a tool for
writing it). Whether that is true depends on what the Library does
and what the program that uses the Library does.
1. You may copy and distribute verbatim copies of the Library's
complete source code as you receive it, in any medium, provided that
you conspicuously and appropriately publish on each copy an
appropriate copyright notice and disclaimer of warranty; keep intact
all the notices that refer to this License and to the absence of any
warranty; and distribute a copy of this License along with the
Library.
You may charge a fee for the physical act of transferring a copy,
and you may at your option offer warranty protection in exchange for a
fee.
2. You may modify your copy or copies of the Library or any portion
of it, thus forming a work based on the Library, and copy and
distribute such modifications or work under the terms of Section 1
above, provided that you also meet all of these conditions:
a) The modified work must itself be a software library.
b) You must cause the files modified to carry prominent notices
stating that you changed the files and the date of any change.
c) You must cause the whole of the work to be licensed at no
charge to all third parties under the terms of this License.
d) If a facility in the modified Library refers to a function or a
table of data to be supplied by an application program that uses
the facility, other than as an argument passed when the facility
is invoked, then you must make a good faith effort to ensure that,
in the event an application does not supply such function or
table, the facility still operates, and performs whatever part of
its purpose remains meaningful.
(For example, a function in a library to compute square roots has
a purpose that is entirely well-defined independent of the
application. Therefore, Subsection 2d requires that any
application-supplied function or table used by this function must
be optional: if the application does not supply it, the square
root function must still compute square roots.)
These requirements apply to the modified work as a whole. If
identifiable sections of that work are not derived from the Library,
and can be reasonably considered independent and separate works in
themselves, then this License, and its terms, do not apply to those
sections when you distribute them as separate works. But when you
distribute the same sections as part of a whole which is a work based
on the Library, the distribution of the whole must be on the terms of
this License, whose permissions for other licensees extend to the
entire whole, and thus to each and every part regardless of who wrote
it.
Thus, it is not the intent of this section to claim rights or contest
your rights to work written entirely by you; rather, the intent is to
exercise the right to control the distribution of derivative or
collective works based on the Library.
In addition, mere aggregation of another work not based on the Library
with the Library (or with a work based on the Library) on a volume of
a storage or distribution medium does not bring the other work under
the scope of this License.
3. You may opt to apply the terms of the ordinary GNU General Public
License instead of this License to a given copy of the Library. To do
this, you must alter all the notices that refer to this License, so
that they refer to the ordinary GNU General Public License, version 2,
instead of to this License. (If a newer version than version 2 of the
ordinary GNU General Public License has appeared, then you can specify
that version instead if you wish.) Do not make any other change in
these notices.
Once this change is made in a given copy, it is irreversible for
that copy, so the ordinary GNU General Public License applies to all
subsequent copies and derivative works made from that copy.
This option is useful when you wish to copy part of the code of
the Library into a program that is not a library.
4. You may copy and distribute the Library (or a portion or
derivative of it, under Section 2) in object code or executable form
under the terms of Sections 1 and 2 above provided that you accompany
it with the complete corresponding machine-readable source code, which
must be distributed under the terms of Sections 1 and 2 above on a
medium customarily used for software interchange.
If distribution of object code is made by offering access to copy
from a designated place, then offering equivalent access to copy the
source code from the same place satisfies the requirement to
distribute the source code, even though third parties are not
compelled to copy the source along with the object code.
5. A program that contains no derivative of any portion of the
Library, but is designed to work with the Library by being compiled or
linked with it, is called a "work that uses the Library". Such a
work, in isolation, is not a derivative work of the Library, and
therefore falls outside the scope of this License.
However, linking a "work that uses the Library" with the Library
creates an executable that is a derivative of the Library (because it
contains portions of the Library), rather than a "work that uses the
library". The executable is therefore covered by this License.
Section 6 states terms for distribution of such executables.
When a "work that uses the Library" uses material from a header file
that is part of the Library, the object code for the work may be a
derivative work of the Library even though the source code is not.
Whether this is true is especially significant if the work can be
linked without the Library, or if the work is itself a library. The
threshold for this to be true is not precisely defined by law.
If such an object file uses only numerical parameters, data
structure layouts and accessors, and small macros and small inline
functions (ten lines or less in length), then the use of the object
file is unrestricted, regardless of whether it is legally a derivative
work. (Executables containing this object code plus portions of the
Library will still fall under Section 6.)
Otherwise, if the work is a derivative of the Library, you may
distribute the object code for the work under the terms of Section 6.
Any executables containing that work also fall under Section 6,
whether or not they are linked directly with the Library itself.
6. As an exception to the Sections above, you may also combine or
link a "work that uses the Library" with the Library to produce a
work containing portions of the Library, and distribute that work
under terms of your choice, provided that the terms permit
modification of the work for the customer's own use and reverse
engineering for debugging such modifications.
You must give prominent notice with each copy of the work that the
Library is used in it and that the Library and its use are covered by
this License. You must supply a copy of this License. If the work
during execution displays copyright notices, you must include the
copyright notice for the Library among them, as well as a reference
directing the user to the copy of this License. Also, you must do one
of these things:
a) Accompany the work with the complete corresponding
machine-readable source code for the Library including whatever
changes were used in the work (which must be distributed under
Sections 1 and 2 above); and, if the work is an executable linked
with the Library, with the complete machine-readable "work that
uses the Library", as object code and/or source code, so that the
user can modify the Library and then relink to produce a modified
executable containing the modified Library. (It is understood
that the user who changes the contents of definitions files in the
Library will not necessarily be able to recompile the application
to use the modified definitions.)
b) Use a suitable shared library mechanism for linking with the
Library. A suitable mechanism is one that (1) uses at run time a
copy of the library already present on the user's computer system,
rather than copying library functions into the executable, and (2)
will operate properly with a modified version of the library, if
the user installs one, as long as the modified version is
interface-compatible with the version that the work was made with.
c) Accompany the work with a written offer, valid for at least
three years, to give the same user the materials specified in
Subsection 6a, above, for a charge no more than the cost of
performing this distribution.
d) If distribution of the work is made by offering access to copy
from a designated place, offer equivalent access to copy the above
specified materials from the same place.
e) Verify that the user has already received a copy of these
materials or that you have already sent this user a copy.
For an executable, the required form of the "work that uses the
Library" must include any data and utility programs needed for
reproducing the executable from it. However, as a special exception,
the materials to be distributed need not include anything that is
normally distributed (in either source or binary form) with the major
components (compiler, kernel, and so on) of the operating system on
which the executable runs, unless that component itself accompanies
the executable.
It may happen that this requirement contradicts the license
restrictions of other proprietary libraries that do not normally
accompany the operating system. Such a contradiction means you cannot
use both them and the Library together in an executable that you
distribute.
7. You may place library facilities that are a work based on the
Library side-by-side in a single library together with other library
facilities not covered by this License, and distribute such a combined
library, provided that the separate distribution of the work based on
the Library and of the other library facilities is otherwise
permitted, and provided that you do these two things:
a) Accompany the combined library with a copy of the same work
based on the Library, uncombined with any other library
facilities. This must be distributed under the terms of the
Sections above.
b) Give prominent notice with the combined library of the fact
that part of it is a work based on the Library, and explaining
where to find the accompanying uncombined form of the same work.
8. You may not copy, modify, sublicense, link with, or distribute
the Library except as expressly provided under this License. Any
attempt otherwise to copy, modify, sublicense, link with, or
distribute the Library is void, and will automatically terminate your
rights under this License. However, parties who have received copies,
or rights, from you under this License will not have their licenses
terminated so long as such parties remain in full compliance.
9. You are not required to accept this License, since you have not
signed it. However, nothing else grants you permission to modify or
distribute the Library or its derivative works. These actions are
prohibited by law if you do not accept this License. Therefore, by
modifying or distributing the Library (or any work based on the
Library), you indicate your acceptance of this License to do so, and
all its terms and conditions for copying, distributing or modifying
the Library or works based on it.
10. Each time you redistribute the Library (or any work based on the
Library), the recipient automatically receives a license from the
original licensor to copy, distribute, link with or modify the Library
subject to these terms and conditions. You may not impose any further
restrictions on the recipients' exercise of the rights granted herein.
You are not responsible for enforcing compliance by third parties with
this License.
11. If, as a consequence of a court judgment or allegation of patent
infringement or for any other reason (not limited to patent issues),
conditions are imposed on you (whether by court order, agreement or
otherwise) that contradict the conditions of this License, they do not
excuse you from the conditions of this License. If you cannot
distribute so as to satisfy simultaneously your obligations under this
License and any other pertinent obligations, then as a consequence you
may not distribute the Library at all. For example, if a patent
license would not permit royalty-free redistribution of the Library by
all those who receive copies directly or indirectly through you, then
the only way you could satisfy both it and this License would be to
refrain entirely from distribution of the Library.
If any portion of this section is held invalid or unenforceable under
any particular circumstance, the balance of the section is intended to
apply, and the section as a whole is intended to apply in other
circumstances.
It is not the purpose of this section to induce you to infringe any
patents or other property right claims or to contest validity of any
such claims; this section has the sole purpose of protecting the
integrity of the free software distribution system which is
implemented by public license practices. Many people have made
generous contributions to the wide range of software distributed
through that system in reliance on consistent application of that
system; it is up to the author/donor to decide if he or she is willing
to distribute software through any other system and a licensee cannot
impose that choice.
This section is intended to make thoroughly clear what is believed to
be a consequence of the rest of this License.
12. If the distribution and/or use of the Library is restricted in
certain countries either by patents or by copyrighted interfaces, the
original copyright holder who places the Library under this License
may add an explicit geographical distribution limitation excluding those
countries, so that distribution is permitted only in or among
countries not thus excluded. In such case, this License incorporates
the limitation as if written in the body of this License.
13. The Free Software Foundation may publish revised and/or new
versions of the Lesser General Public License from time to time.
Such new versions will be similar in spirit to the present version,
but may differ in detail to address new problems or concerns.
Each version is given a distinguishing version number. If the Library
specifies a version number of this License which applies to it and
"any later version", you have the option of following the terms and
conditions either of that version or of any later version published by
the Free Software Foundation. If the Library does not specify a
license version number, you may choose any version ever published by
the Free Software Foundation.
14. If you wish to incorporate parts of the Library into other free
programs whose distribution conditions are incompatible with these,
write to the author to ask for permission. For software which is
copyrighted by the Free Software Foundation, write to the Free
Software Foundation; we sometimes make exceptions for this. Our
decision will be guided by the two goals of preserving the free status
of all derivatives of our free software and of promoting the sharing
and reuse of software generally.
NO WARRANTY
15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
LIBRARY IS WITH YOU. SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
DAMAGES.
END OF TERMS AND CONDITIONS
How to Apply These Terms to Your New Libraries
If you develop a new library, and you want it to be of the greatest
possible use to the public, we recommend making it free software that
everyone can redistribute and change. You can do so by permitting
redistribution under these terms (or, alternatively, under the terms
of the ordinary General Public License).
To apply these terms, attach the following notices to the library.
It is safest to attach them to the start of each source file to most
effectively convey the exclusion of warranty; and each file should
have at least the "copyright" line and a pointer to where the full
notice is found.
Copyright (C)
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation; either
version 2.1 of the License, or (at your option) any later version.
This library 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
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
Also add information on how to contact you by electronic and paper mail.
You should also get your employer (if you work as a programmer) or
your school, if any, to sign a "copyright disclaimer" for the library,
if necessary. Here is a sample; alter the names:
Yoyodyne, Inc., hereby disclaims all copyright interest in the
library `Frob' (a library for tweaking knobs) written by James
Random Hacker.
, 1 April 1990
Ty Coon, President of Vice
That's all there is to it!
*/
mszip_dst = ""
#deffunc local OutputQrcodelibDll str _dir
mszip = {"ClHlwBgATgIAagAAAAAAAABqAAAAAAAAxTkAAENL7X17XFNXtvBJzgGOEkmqUaml
Sm3ascXaQADBIL7AV30EA4lWIbUSB1CBQlK1ExAbMsNhm45zp/PoTO837e28X33M
fI6dmXYCURBrWx+tpbWdWuu0B6MtfQG+ON9a++xAQNu59/vu98f33Yu/nXPOXnuv
vfbaa6299tr7HFfeu5fjO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M57+XcPWflnAfmZFgv
Wf8174U8Oe/43F/ln8rfPu87856at39e27zD816d9/68j+epmzb43Z2x5vHmm8y3
m63mBeZ15m3mh83fMgfNvzT/zvy8uQPG4TXzBfNn5vj0xPTk9K+l56UvTC9Kr073
pj+Uviu9Jf2R9J+k/zW9K/299MyMjRm/yngn4/2MnoyPM77IuJyhtYyxGCyTLVMt
t1lmWjKBkwUWm2WdpcxSbqm2bLc8bHnE8l3LU5ZfWn5v+aPlsOWYpdvyAYxyvyUx
MzUzLXNFpj3zvswfZD4Oox7KLMnalBXK6sg6knU8682svqyF2Uuy12c3ZpPsH2T/
JPsX2X/IfiP73exz2b3ZfdlXsrWzxdlJwBV1TYZxjF+aj0JfhHwx/5n8/fl/ze/O
/zx/IF/9/2jQjhnMRnOyOcWcajaZZ5hnmv/byl/7978A"}
MSZipFromCode mszip, mszip_dst
bsave _dir + "\\qrcodelib.dll", mszip_dst, stat
return
// ezphp.phpが必要だけど無いときに出力
#deffunc local OutputEzphpPhp str _dir
buf = {"prepare($postVal);
\ $stmt->execute($prms);
\ if( strtoupper(substr(trim($postVal),0,6)) == 'SELECT' ){
\ if($needsRetJson){
\ header('Content-Type: application/json; charset=utf-8');
\ return json_encode($stmt->fetchAll(PDO::FETCH_ASSOC));
\ }else {
\ $isFirst = true;
\ $retVar = '';
\ while( $row = $stmt->fetch(PDO::FETCH_ASSOC) ){
\ foreach ($row as $key => $value){
\ if($isFirst){
\ $isFirst = false;
\ }else{
\ $retVar .= "\\r\\n";
\ }
\ $retVar .= $key.':'.str_replace(["\\r\\n", "\\r", "\\n"], '
', $value);
\ }
\ }
\ return $retVar;
\ }
\ }
\ return '';
\ } catch (Exception $e) {
\ echo '#Error - ' . $e->getMessage();
\ exit;
\ }
}
"}
notesel buf
if (hspstat & $20000) == 0 {
// shifjis -> utf8
nkfcnv@ buf, buf, "Sw", , strlen(buf)*2
}
notesave _dir + "\\ezphp.php"
noteunsel
return
#global
onerror goto *err_note@ezLocalDishJs : if 0 : *err_note@ezLocalDishJs : if 1 {
dialog "【起動について】\n\nezLocalJS コマンドも必須なので書いてください。\n\n----------\n\n【起動させないためには】\n\nもし、一時的に ezlocal-dish-js を使いたくないという場合は、\n\n#include \"ezlocal-dish-js.hsp\"\nezlocalJS\n\n両方の行をコメントアウトしてください。", 1, "ezlocal-dish-js"
end
end
stop
}
#endif
#if 0
// hs ファイル //////////////////////////////////////////////////////////////
%type
拡張命令
%url
https://github.com/MIZUSHIKI/HSP-Module
%port
Win
%index
ezLocalJS
HSP3Dish.js のローカル動作環境を構築と HSP3Dish helper の実行補助
%group
ツール実行命令
%prm
%inst
HSP3Dish.js をローカルで動作させる為の環境としてnginxを自動でインストールできます。
画面に表示される案内を読みインストールボタンを押してください。
(nginxはレジストリを書き換えません。)
インストール後は下記のような HSP3Dish helper の実行補助を行います。
・HSP3Dish helper 起動とファイル名等の指定 (+出力HTMLの調整)
・nginx(ローカルサーバ)の起動
・テスト用ディレクトリへのファイルコピー
・ローカル実行URLへのリンク表示
・QRコードを利用してスマホからローカル実行URLへ簡単にアクセス
【環境のアンインストールについて】
インストールする nginxはレジストリを書き換えません。
「C:\nginx」フォルダを削除すればアンインストール完了です。
%sample
#include "hsp3dish.as"
#include "ezlocal-dish-js.hsp"
ezLocalJS
// このモジュールを使用しないときは ezLocalJS の行だけでなく
// #include "ezlocal-dish-js.hsp" の行もコメントアウトしてください。
/*
// ブラウザへのデータ保存の仕方
// ・ezlocal-dish-jsツールのオプション「ブラウザ上にデータ保存できるようにする」をチェック
data="保存データ"
bsave "save/data.txt", data ; ← saveフォルダを指定。パス指定時は必ず「/」で区切る。
devcontrol "syncfs"
*/
%href
%
// /hs ファイル /////////////////////////////////////////////////////////////
================================================================================
- Changelogs
--------------------------------------------------------------------------------
2.1 2024/ 9/10
---------------------
- PHP-FPM(PHP実行環境)もインストールすることにした
- ezphp.phpや新規サンプル(sample2,sample3)を追加同梱
- オプションにスマホ横向き全画面FIT(β機能)を追加。サンプル(sample4)追加同梱。
- オプションの表示解像度調整対象からタブレットを除外
- その他の細かい箇所の変更と修正
2.0.1 2024/ 8/26
---------------------
- ローカルIP取得が上手くいかないことがあったのでWi-Fi項目を優先取得に修正
2.0 2024/ 8/23
---------------------
- インストールするローカルサーバ環境をXAMPPからnginxに変更
- 127.0.0.1(localhost)のrootフォルダをデフォルト値でなく設定値を調べるようにした
- IPv4アドレスの取得を英語版でも取得できるように修正
- その他の細かい箇所の変更と修正
1.1 2024/ 8/20
---------------------
- 二重起動防止の方法を起動させないのでなく前回のウィンドウを消すことに変更
- HTML調整でシステムメッセージとコントロール非表示のタイミングを変更
- HTML調整で画面サイズに合わせた表示解像度化をスマホだけでなくタブレットにも適用
- 画面サイズ指定されてることが明らかなのにhsp3dish.iniがない場合に警告を表示
- hsp3dish.iniオプションのsx,syに文字列の指定も可能にした
- hsp3dish.ini作成時やdataファルダの有無注意喚起時にdotfw.asを考慮するようにした
- hspinet,mod_regexpを独自関数登録していたがincludeに戻した
- その他の細かい箇所の変更と修正
1.0.1 2024/ 8/18
---------------------
- hsドキュメント追加(モジュール内)
- オプションの非対象バージョン時OFFと変数定義位置修正
1.0 2024/ 8/16
---------------------
- 公開
================================================================================
#endif