Ticket #8863: mythsystem_liirc_locking.diff

File mythsystem_liirc_locking.diff, 1.1 KB (added by Ian Clark <mrrooster@…>, 14 years ago)

svn diff file

  • trunk/mythtv/libs/libmythdb/mythsystem.cpp

     
    4242#include "mythverbose.h"
    4343#include "exitcodes.h"
    4444
    45 #ifdef USE_LIRC
    46 #include "lircevent.h"
     45#if CONFIG_LIRC
     46#include "../libmythui/lircevent.h"
    4747#endif
    4848
    4949#ifdef USE_JOYSTICK_MENU
     
    251251    }
    252252
    253253    myth_system_pre_flags( flags, ready_to_lock );
     254
     255#if CONFIG_LIRC
     256    bool lirc_lock_flag = !(flags & MYTH_SYSTEM_DONT_BLOCK_LIRC);
     257    LircEventLock lirc_lock(lirc_lock_flag && ready_to_lock);
     258#endif
     259
    254260#ifndef USING_MINGW
    255261    pid_t   pid;
    256262
     
    302308{
    303309    ready_to_lock = gCoreContext->HasGUI() && gCoreContext->IsUIThread();
    304310
    305 #ifdef USE_LIRC
    306     bool lirc_lock_flag = !(flags & MYTH_SYSTEM_DONT_BLOCK_LIRC);
    307     LircEventLock lirc_lock(lirc_lock_flag && ready_to_lock);
    308 #endif
    309 
    310311#ifdef USE_JOYSTICK_MENU
    311312    bool joy_lock_flag = !(flags & MYTH_SYSTEM_DONT_BLOCK_JOYSTICK_MENU);
    312313    JoystickMenuEventLock joystick_lock(joy_lock_flag && ready_to_lock);