~ubuntu-branches/ubuntu/saucy/bochs/saucy-proposed

« back to all changes in this revision

Viewing changes to gui/gui.cc

  • Committer: Bazaar Package Importer
  • Author(s): David Futcher
  • Date: 2009-04-30 07:46:11 UTC
  • mfrom: (1.1.11 upstream) (4.1.7 squeeze)
  • Revision ID: james.westby@ubuntu.com-20090430074611-6dih80a5mk2uvxhk
Tags: 2.3.7+20090416-1ubuntu1
* Merge from debian unstable (LP: #370427), remaining changes:
  - debian/patches/12_no-ssp.patch: Build bios with -fno-stack-protector
  - Add Replaces/Conflicts for bochsbios-qemu (<< 2.3.6-2)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
/////////////////////////////////////////////////////////////////////////
2
 
// $Id: gui.cc,v 1.105 2008/05/04 09:29:45 vruppert Exp $
 
2
// $Id: gui.cc,v 1.111 2009/03/25 18:33:38 vruppert Exp $
3
3
/////////////////////////////////////////////////////////////////////////
4
4
//
5
5
//  Copyright (C) 2002  MandrakeSoft S.A.
22
22
//
23
23
//  You should have received a copy of the GNU Lesser General Public
24
24
//  License along with this library; if not, write to the Free Software
25
 
//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 
25
//  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
26
26
 
27
27
 
28
28
#include <signal.h>
29
29
#include "bochs.h"
 
30
#include "keymap.h"
30
31
#include "iodev.h"
31
32
#include "gui/bitmaps/floppya.h"
32
33
#include "gui/bitmaps/floppyb.h"
102
103
bx_gui_c::bx_gui_c(void)
103
104
{
104
105
  put("GUI"); // Init in specific_init
105
 
  settype(GUILOG);
106
106
  statusitem_count = 0;
107
107
  framebuffer = NULL;
108
108
}
247
247
void bx_gui_c::update_drive_status_buttons(void)
248
248
{
249
249
  BX_GUI_THIS floppyA_status = DEV_floppy_get_media_status(0)
250
 
    && (SIM->get_param_enum(BXPN_FLOPPYA_STATUS)->get() == BX_INSERTED);
 
250
    && (SIM->get_param_bool(BXPN_FLOPPYA_STATUS)->get());
251
251
  BX_GUI_THIS floppyB_status = DEV_floppy_get_media_status(1)
252
 
    && (SIM->get_param_enum(BXPN_FLOPPYB_STATUS)->get() == BX_INSERTED);
 
252
    && (SIM->get_param_bool(BXPN_FLOPPYB_STATUS)->get());
253
253
  Bit32u handle = DEV_hd_get_first_cd_handle();
254
254
  BX_GUI_THIS cdromD_status = DEV_hd_get_cd_media_status(handle);
255
255
  if (BX_GUI_THIS floppyA_status)
283
283
 
284
284
void bx_gui_c::floppyA_handler(void)
285
285
{
286
 
  if (SIM->get_param_enum(BXPN_FLOPPYA_DEVTYPE)->get() == BX_FLOPPY_NONE)
 
286
  if (SIM->get_param_enum(BXPN_FLOPPYA_DEVTYPE)->get() == BX_FDD_NONE)
287
287
    return; // no primary floppy device present
288
288
  if (BX_GUI_THIS dialog_caps & BX_GUI_DLG_FLOPPY) {
289
289
    // instead of just toggling the status, call win32dialog to bring up
301
301
 
302
302
void bx_gui_c::floppyB_handler(void)
303
303
{
304
 
  if (SIM->get_param_enum(BXPN_FLOPPYB_DEVTYPE)->get() == BX_FLOPPY_NONE)
 
304
  if (SIM->get_param_enum(BXPN_FLOPPYB_DEVTYPE)->get() == BX_FDD_NONE)
305
305
    return; // no secondary floppy device present
306
306
  if (BX_GUI_THIS dialog_caps & BX_GUI_DLG_FLOPPY) {
307
307
    // instead of just toggling the status, call win32dialog to bring up