I have researched quite a bit but have yet to find and answer to my question, so I thought I'd ask here. I am currently using the latest version of ACR.UserDialogs (as of 2/12/2020) and I am unable to get an Alert to cancel when touching anywhere on the screen on an android device. I can only get the alert to dismiss by touching the dismiss button on the alert itself. Touch anywhere to cancel an Alert is available on the native Alert. Is there a way to achieve the same using the Alert from ACR.UserDialogs?
Here is the call to an alert:
UserDialogs.Instance.Alert("Some Message", "Some Title", "Cancel");
Related
I'm currently building an app that would detect specific keywords in a slack message (channel or DM) and will highlight these words (by using an hyperlink markdown).
Although I'm facing an issue, I'd like to open a Slack modal view when a user clicks a click. If I understand properly the click should fire an event with a trigger_id and then I can use this idea to fire the views.open event and open the modal.
My question is if clicking a link (the highlighted word) can be an entry point for an user interaction with the app. If not is there a way to generate this event (and the trigger_id)?
Thank you for your help
Found the answer on Slack community channel. It's not possible to open a modal on a link click. This is not a supported action at the moment.
I need to check for unsaved data when a packaged app is closed (using the close button at the bottom of the screen and then pressing the X that is top left when the app appears reduced size).
I've managed to add an event listener for the low battery condition and this works as expected. But looking at https://developer.mozilla.org/en-US/docs/Web/Events I can't decide which event is correct for closing an app.
The obvious name -- close -- seems to be something to do with web sockets.
mozbrowserclose seems to be triggered when closing by the app's software.
XUL close "the user presses the close button" seems like the appropriate one, but when trying
window.addEventListener("close", function( event )
{
window.alert("closing");
}, false);
the app closes without triggering the alert.
DOMWindowClose seems to be specific for close by window.close in software
mozbrowserclose seems to be specific to iframes
So ... does anybody know the correct event to trap ?
Phone is ZTE Open C with FFOS 1.3.
It looks like this is a bug -- https://bugzilla.mozilla.org/show_bug.cgi?id=996754 "User-terminated apps do not receive 'beforeunload' event"
I am working on a game on OSX with In App Purchases.
I am trying to detect when the Popup that says "Thank You, Your purchase was Successful." At the end of a successful Purchase by the user.
The Problem that I am having is I need to hide the mouse and resume input on the game after this message has been dismissed, but I can't find a suitable place to do this.
How can I find out if the OK button has been pressed on this message box?
Okay, so I found a fix to my problem.
I couldn't find a way to detect when an alert is shown from another Application, as all the the In App Purchase popups come from the App Store.
The fix I used was to make sure that the App Store was open before starting the transaction. This means that OS, whether or not you are in full screen, will automatically take you to the App Store. This causes the Alerts to be shown as sheets inside the App Store rather than in front of your application. Problem solved.
I open the App Store immediately before instigating the transaction by calling this line of code:
[[NSApp mainWindow] makeKeyAndOrderFront:[NSApp mainWindow]];
Then once the transaction finishes I grab focus on my App again.
I'm a new Mac programmer writing my first mac app, actually porting an existing iOS app to MAC.
The app does a lot of remote communication, so when the user kicks off an operation, I want to display a busy window (or message box, or NSAlert maybe), until the operation is completed, then dismiss it programmatically, or the user can click cancel to stop it.
The busy window prevents the user from doing anything until that operation is completed.
The busy window should have a progress spinner, some text, and a cancel button.
Its such a simple thing yet I'm having problems with it because I dont really know MAC programming, getting myself frustrated.
Can anybody offer suggestions, or already written code for it. I hope some code for this already exists because I cant believe I'm the only person in the world who needs things kind of busy window.
Thanks for any help.
You mean something like this:
http://www.developers-life.com/example-nspanel-with-nsprogressindicator.html
???
Source code is available, too (link at the end of the article).
You can just modify the NSPanel in Xcode and add a "Cancel" button that you connect to your cancel action.
I am working on WP7 app.
In this am launching youtube url in Yotube app.
To return to my app from YouTube user will have to click back button twice, as per my research this is a known issue.
I need to show a message(inside youtube) to user like "Press back button again to return" whenever he presses back button.
How can I achieve this?
Welcome any comment!!
If I understand you correctly, you want to display a popup in another application? In your case a Youtube-app?
Unfortunately, you can not change the behavior of another app. There aren't any hooks in other apps from your own app.
That is not possible.