mirror of https://github.com/PCSX2/pcsx2.git
Potential fix for Issue 495: missing keyboard handler in Linux.
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2306 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
8a4d58ff76
commit
a6b00be571
|
@ -390,6 +390,7 @@ static void intExecute()
|
|||
|
||||
static void intCheckExecutionState()
|
||||
{
|
||||
SysCoreThread::Get().OnVsyncInThread();
|
||||
SysCoreThread::Get().StateCheckInThread();
|
||||
}
|
||||
|
||||
|
|
|
@ -941,9 +941,17 @@ void PluginManager::Open( PluginsEnum_t pid )
|
|||
|
||||
void PluginManager::Open()
|
||||
{
|
||||
Console.WriteLn( Color_StrongBlue, "Opening plugins..." );
|
||||
// Spam stopper: If all plugins are already opened, then return before writing any logs. >_<
|
||||
|
||||
const PluginInfo* pi = tbl_PluginInfo; do {
|
||||
if( !m_info[pi->id].IsOpened ) break;
|
||||
} while( ++pi, pi->shortname != NULL );
|
||||
|
||||
if( pi->shortname == NULL ) return;
|
||||
|
||||
Console.WriteLn( Color_StrongBlue, "Opening plugins..." );
|
||||
|
||||
pi = tbl_PluginInfo; do {
|
||||
Open( pi->id );
|
||||
// If GS doesn't support GSopen2, need to wait until call to GSopen
|
||||
// returns to populate pDsp. If it does, can initialize other plugins
|
||||
|
|
|
@ -279,6 +279,10 @@ void SysCoreThread::_reset_stuff_as_needed()
|
|||
}
|
||||
}
|
||||
|
||||
void SysCoreThread::OnVsyncInThread()
|
||||
{
|
||||
}
|
||||
|
||||
void SysCoreThread::StateCheckInThread()
|
||||
{
|
||||
GetMTGS().RethrowException();
|
||||
|
@ -286,6 +290,8 @@ void SysCoreThread::StateCheckInThread()
|
|||
if( !m_hasValidState )
|
||||
throw Exception::RuntimeError( "Invalid emulation state detected; Virtual machine threads have been cancelled." );
|
||||
|
||||
//OnVsyncInThread();
|
||||
|
||||
_reset_stuff_as_needed();
|
||||
}
|
||||
|
||||
|
|
|
@ -217,6 +217,7 @@ public:
|
|||
|
||||
bool HasPendingStateChangeRequest() const;
|
||||
virtual void StateCheckInThread();
|
||||
virtual void OnVsyncInThread();
|
||||
|
||||
virtual const wxString& GetElfOverride() const { return m_elf_override; }
|
||||
virtual void SetElfOverride( const wxString& elf );
|
||||
|
|
|
@ -542,6 +542,7 @@ protected:
|
|||
virtual void OnResumeInThread( bool IsSuspended );
|
||||
virtual void OnSuspendInThread();
|
||||
virtual void OnCleanupInThread();
|
||||
virtual void OnVsyncInThread();
|
||||
virtual void ExecuteTaskInThread();
|
||||
};
|
||||
|
||||
|
|
|
@ -163,9 +163,10 @@ void AppCoreThread::OnCleanupInThread()
|
|||
extern int TranslateGDKtoWXK( u32 keysym );
|
||||
#endif
|
||||
|
||||
void AppCoreThread::StateCheckInThread()
|
||||
void AppCoreThread::OnVsyncInThread()
|
||||
{
|
||||
_parent::StateCheckInThread();
|
||||
_parent::OnVsyncInThread();
|
||||
|
||||
if( !pxAssert(g_plugins!=NULL) ) return;
|
||||
|
||||
const keyEvent* ev = PADkeyEvent();
|
||||
|
@ -196,6 +197,11 @@ void AppCoreThread::StateCheckInThread()
|
|||
wxGetApp().PostPadKey( m_kevt );
|
||||
}
|
||||
|
||||
void AppCoreThread::StateCheckInThread()
|
||||
{
|
||||
_parent::StateCheckInThread();
|
||||
}
|
||||
|
||||
// To simplify settings application rules and re-entry conditions, the main App's implementation
|
||||
// of ApplySettings requires that the caller manually ensure that the thread has been properly
|
||||
// suspended. If the thread has mot been suspended, this call will fail *silently*.
|
||||
|
|
|
@ -150,6 +150,8 @@ void GSPanel::OnShowMouse( wxMouseEvent& evt )
|
|||
|
||||
void GSPanel::OnHideMouseTimeout( wxTimerEvent& evt )
|
||||
{
|
||||
if( CoreThread.GetExecutionMode() != SysThreadBase::ExecMode_Opened ) return;
|
||||
|
||||
SetCursor( wxCursor( wxCURSOR_BLANK ) );
|
||||
m_CursorShown = false;
|
||||
}
|
||||
|
|
|
@ -656,6 +656,8 @@ static jmp_buf m_SetJmp_StateCheck;
|
|||
|
||||
static void recCheckExecutionState()
|
||||
{
|
||||
SysCoreThread::Get().OnVsyncInThread();
|
||||
|
||||
#if PCSX2_SEH
|
||||
SysCoreThread::Get().StateCheckInThread();
|
||||
|
||||
|
@ -669,6 +671,7 @@ static void recCheckExecutionState()
|
|||
// necessary:
|
||||
|
||||
pxAssert( !eeRecIsReset ); // should only be changed during suspended thread states
|
||||
|
||||
if( SysCoreThread::Get().HasPendingStateChangeRequest() )
|
||||
{
|
||||
longjmp( m_SetJmp_StateCheck, SetJmp_Dispatcher );
|
||||
|
|
Loading…
Reference in New Issue