Im building a Unity game for windows and mac.
They both have the same codebase and little to nothing changes between the Windows and OSX versions of the game.
On OSX every time I quit the game it gives me a "Do you really want to quit?" message which is presented to the user before "OnApplicationQuit" is even called in any script..
I want to get rid of this message, If I want to display a message for quit it would definitely be a better message than "Do you really want to quit?"
Has anyone else come across this issue and is there some way to fix it ??
Thanks for any help.
UPDATE
the only thing I have found to override this is a native plugin to override the window close event and send -[NSApplication terminate:] instead. Which may work for my needs right now, but it is likely to create a whole new avenue of issues later on.
Related
I am currently developing a game using Unity3d and I would like to have it open for downloading while I'm making it, so that if there are mistakes or bugs i don't notice, it'll be caught earlier. Before releasing the first playable version, I added an installer.
So, i put it up on Gamejolt (it's like a free version of steam), and I tested it by downloading it. When i tried to open the file, a screen pops out saying, "Windows protected your computer" and it keeps popping out every time. Is it okay to put a "more details" but i guess it will scare people away from downloading it because of the "This app might put your computer at risk" warning.
Is there a way to get Windows to recognize the app so that the warning message will not pop out?
I've been tasked with adding gesture support to our product which was simple enough on a new Windows 8 machine - I just added WM_GESTURE to our wndproc and everything worked as expected. However, when it came to getting it to work on a Win7 machine things have been very different. I receive no gesture messages at all. Even spy++ shows no gesture messages being sent to my application. I've managed to get touch messages working using RegisterTouchWindow() but I know that I won't get an gesture messages when touch is disabled, so that was only done for test purposes. I read somewhere that "flicks" can interfere, so I have disabled flicks, both from the control panel, and from code using SetOpt(). I've even tried hooking in to GetMessage using SetWindowsHookEx. Nothing I do works. I've tried the example programs from the Microsoft Touch Pack, and gestures appear to be working there, in that everything works as expected. I've read all the documentation I can find, and still can't work out what's going wrong. Can anyone provide any more insight into this? I feel like it should "just work", but it really isn't!
Thanks in advance.
I've got an Adobe AIR application written in pure AS3 that has some functionality that happens when the user is idle and then returns to the normal state when the user returns. I'm detecting this activity with the following code:
NativeApplication.nativeApplication.idleThreshold = 180;
NativeApplication.nativeApplication.addEventListener(Event.USER_IDLE, onUserIdle);
NativeApplication.nativeApplication.addEventListener(Event.USER_PRESENT, onUserPresent);
The onUserIdle method is called after 3 minutes as it should be, but then the onUserPresent event is fired almost immediately afterwards. I'm talking milliseconds later. This happens without any user input whatsoever. The bizarre thing is that this does not occur on Windows - only on OSX. And it happens on all flavors of OSX going back to 10.6.3.
Adobe's documentation is incredibly vague on how those events are determined, so I'm not sure if there is something I can do at the system level to fix the problem. Does anyone have any experience with this issue, and if not, any other suggestions on how I can detect user idleness even when the app does not have focus?
Just to preempt the suggestion, I cannot use mouse/keyboard listeners to simulate the same behavior because they do not work if the application loses focus, whereas the NativeApplication events still fire. I've also used NativeProcess to get the output of ioreg to get the hardware idle time as reported by the system, but it does not appear to be affected by the mouse.
I really appreciate any assistance.
Edit: I just discovered that this does not occur when the application is run in an Administrator account on OSX. It only happens in a User account, which only serves to confuse me more.
I figured out what the issue is. When the USER_IDLE event is fired in a user account, we did several things - one of which was forcibly kill the Dock in order to make sure it was hidden from the screen. For whatever reason, this resets the internally available idleThreshold count. This was not only happening in AIR - it was also happening when monitored through Terminal and it appears there is absolutely nothing that can be done to stop it. The solution was to stop killing the dock. Everything magically worked after that.
I currently have a "dumbphone", but I'm trying to make an app that'll time and store the call duration of incoming calls for windows 7.1 ("7.5") phones, for the user scheduling purposes.
However, after extensive searching and googling, with topics like this one:
Windows Phone 7 - How to calculate call duration or termination
it seems that the Windows 7/7.1 SDK does not allow access to recognizing when a call is coming in. I've read about obscure and unobscure, but that this wouldn't be a good idea since it would start the timer anytime the UI hides the program, not just calls.
I've thought that maybe I could just pull the call duration or the start/end time from the call history, but windows 7 SDK doesn't support that either it seems.
So I decided to seek help. Is there a way to make this work? Is there some clever way to recognize when a call is incoming and stopped? Or some clever way to pull call times/durations? Or maybe a way to detect when the user presses that "accept incoming call" button? Or maybe a way to single out when a call is obscuring the UI?
Any help would be greatly appreciated. Thank you
Due to security reasons your application does not have any kind of accsess to call history ect. So you are in a sendbox and you don't know nothing about phone calls.
From the Windows Phone SDK, there is no way to achieve this!
The only thing I can think of is that when a call comes, the current app gets notified that is now Obscured because a new screen is now on top of it (the caller ID screen), and will get notified when it gets back to focus.
But the truth is that this happens even if a SMS message notification pops on the screen and the user taps to read it, or some app gets a notification pushed...
I'm dealing with Hotkey registration, i can't found a way to make user able to register its hotkey.
I tried ShortcutRecorder but it seems impossible to make it works, for me it crash with some error messages related to CG.
I'd like to know if there is a way to make ShortcutRecorder works with a ARC environment and Xcode 4.0 or if you use other control to grab user Hotkeys.
You should check out this fork of ShortCut Recorder:
https://github.com/youknowone/shortcutrecorder
The original appears to have not been updated in some time but I was able to get this fork running on 10.7 without any changes.