Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose useful Windows API functions to Javascript #31

Open
GoogleCodeExporter opened this issue Aug 28, 2015 · 0 comments
Open

Expose useful Windows API functions to Javascript #31

GoogleCodeExporter opened this issue Aug 28, 2015 · 0 comments

Comments

@GoogleCodeExporter
Copy link

GoogleCodeExporter commented Aug 28, 2015

API functions should accessible in javascript through the "phpdesktop" object, e.g. phpdesktop.SetFullscreen(). Some functions have already been exposed, see the JavascriptApi wiki page.

LaunchProcess() [ShellExecute in Windows API] - equivalent of php system/exec functions. But this one would be exposed to javascript. Advantage of this is that it is parented to root phpdesktop-chrome.exe process, so its execution continues for app's lifetime. Issue #15 provides a link to a forum topic that describes a problem with running php job in background when page is refreshed. ShellExecute would resolve this problem. Issue #163 describes implementation of LaunchProcess/ShellExecute in more details.

Open/Save file dialogs:

CloseWindow()
ExitApplication()

The window functions below will be required for custom window themes using HTML5 (Issue #26):

ShowWindow()
HideWindow()
MinimizeWindow()
MaximizeWindow()
RestoreWindow()
MoveWindow()
ResizeWindow()

SetFullscreen() - see Issue #38 "Javascript API to set fullscreen".

Exposing the windows API functions to PHP would be in a form of a PHP example,
that shows how to use the w32api experimental extension
(http://php.net/manual/en/book.w32api.php) or something similar.

Regarding functions to show a dialog to open/save a file, or browser for folder, see what options to these functions we could expose:

Original issue reported on code.google.com by [email protected] on 26 May 2013 at 7:34

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants