~ubuntu-branches/ubuntu/trusty/vice/trusty

« back to all changes in this revision

Viewing changes to src/arch/sdl/xcbm2_ui.c

  • Committer: Package Import Robot
  • Author(s): Laszlo Boszormenyi (GCS)
  • Date: 2013-07-28 20:38:23 UTC
  • mfrom: (1.2.5)
  • mto: This revision was merged to the branch mainline in revision 27.
  • Revision ID: package-import@ubuntu.com-20130728203823-w495rps5wuykespp
Tags: upstream-2.4.dfsg
ImportĀ upstreamĀ versionĀ 2.4.dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
34
34
#include "cbm2.h"
35
35
#include "cbm2mem.h"
36
36
#include "lib.h"
 
37
#include "machine.h"
37
38
#include "menu_cbm2cart.h"
38
39
#include "menu_cbm2hw.h"
39
40
#include "menu_common.h"
267
268
 
268
269
int cbm2ui_init(void)
269
270
{
 
271
    cbm2_font_8 = lib_malloc(8 * 256);
270
272
    cbm2_font_14 = lib_malloc(14 * 256);
271
 
    cbm2_font_8 = lib_malloc(8 * 256);
272
273
 
273
 
    if (cbm2_is_c500()) {
274
 
        sdl_ui_set_menu_params = NULL;
275
 
        sdl_ui_set_menu_font(mem_chargen_rom + 0x800, 8, 8);
276
 
        sdl_ui_set_main_menu(xcbm5x0_main_menu);
277
 
        sdl_video_canvas_switch(1);
278
 
    } else {
279
 
        sdl_ui_set_menu_params = cbm2ui_set_menu_params;
280
 
        sdl_ui_set_main_menu(xcbm6x0_7x0_main_menu);
281
 
    }
 
274
    sdl_ui_set_menu_params = cbm2ui_set_menu_params;
 
275
    sdl_ui_set_main_menu(xcbm6x0_7x0_main_menu);
282
276
 
283
277
    sdl_vkbd_set_vkbd(&vkbd_cbm2);
284
278
 
302
296
    lib_free(cbm2_font_14);
303
297
    lib_free(cbm2_font_8);
304
298
}
 
299
 
 
300
int cbm5x0ui_init(void)
 
301
{
 
302
    cbm2_font_8 = lib_malloc(8 * 256);
 
303
 
 
304
    sdl_ui_set_menu_params = NULL;
 
305
    sdl_ui_set_menu_font(mem_chargen_rom + 0x800, 8, 8);
 
306
    sdl_ui_set_main_menu(xcbm5x0_main_menu);
 
307
    sdl_video_canvas_switch(1);
 
308
 
 
309
    sdl_vkbd_set_vkbd(&vkbd_cbm2);
 
310
 
 
311
#ifdef HAVE_FFMPEG
 
312
    sdl_menu_ffmpeg_init();
 
313
#endif
 
314
 
 
315
    return 0;
 
316
}
 
317
 
 
318
void cbm5x0ui_shutdown(void)
 
319
{
 
320
#ifdef SDL_DEBUG
 
321
    fprintf(stderr,"%s\n",__func__);
 
322
#endif
 
323
 
 
324
#ifdef HAVE_FFMPEG
 
325
    sdl_menu_ffmpeg_shutdown();
 
326
#endif
 
327
    lib_free(cbm2_font_8);
 
328
}