File "winemapping.bas"
Path: /exe2unix/winemapping.bas
File size: 1.04 KB
MIME-type:
Charset: utf-8
#COMPILE EXE "winemapping.exe"
#DIM ALL
#REGISTER NONE
#RESOURCE "winemapping.pbr"
MACRO MyMsgBox(hd,m,t,st) = MessageBox(hd,m,t,st)
#INCLUDE ONCE "Win32Api.inc"
#INCLUDE ONCE "inc/Exe2Unix.inc"
'--------------------------------------------------------------------------------
FUNCTION PBMAIN
LOCAL r AS STRING
LOCAL i AS LONG
' Create exe icon in Unix dock and Unix file explorer
Me2Unix 0, 1 ' askConfirmation=%FALSE, showInAppMenu=%TRUE
' Are we under Linux?
IF NOT IsOnUnix() THEN
?"This program must be run under Unix.", _
%MB_ICONWARNING, EXE.NAME$
EXIT FUNCTION
END IF
' Get all Wine drives and their mapping
GetWineDrivesMapping()
' Show result
FOR i = 0 TO UBOUND(dosdevices)
r += UCASE$(LEFT$(dosdevices(i),2)) + " -> " + MID$(dosdevices(i), 3) + $CRLF
NEXT
r += "(" + FORMAT$(1+UBOUND(dosdevices)) + " Wine drives in total)."
?r, %MB_ICONINFORMATION, EXE.NAME$
END FUNCTION
'--------------------------------------------------------------------------------