… | |
… | |
891 | can_events => 1, |
891 | can_events => 1, |
892 | tooltip => "This field shows any known issues with your config or driver, such as " |
892 | tooltip => "This field shows any known issues with your config or driver, such as " |
893 | . "a non-accelerated display format. You can try to work around these issues " |
893 | . "a non-accelerated display format. You can try to work around these issues " |
894 | . "by selecting a different video mode, changing the settings below or " |
894 | . "by selecting a different video mode, changing the settings below or " |
895 | . "by installing the right driver for your graphics card."); |
895 | . "by installing the right driver for your graphics card."); |
|
|
896 | |
|
|
897 | $table->add_at (0, $row, new DC::UI::Label align => 1, text => "UI Theme"); |
|
|
898 | $table->add_at (1, $row++, $FULLSCREEN_ENABLE = new DC::UI::Selector |
|
|
899 | value => $CFG->{uitheme}, |
|
|
900 | options => [ |
|
|
901 | [wood => "Wood (the default)"], |
|
|
902 | [plain => "Plain (very)"], |
|
|
903 | [blue => "Blue"], |
|
|
904 | ], |
|
|
905 | tooltip => "Choose the User Interface theme that you like most :)", |
|
|
906 | on_changed => sub { my ($self, $value) = @_; $CFG->{uitheme} = $value; 0 } |
|
|
907 | ); |
896 | |
908 | |
897 | my $vidmode_tooltip = |
909 | my $vidmode_tooltip = |
898 | "<b>Video Mode.</b> The video mode to use for fullscreen (and the window size for windowed operation). " |
910 | "<b>Video Mode.</b> The video mode to use for fullscreen (and the window size for windowed operation). " |
899 | . "The format is <i>width</i> x <i>height</i> \@ <i>depth-per-channel</i> + <i>alpha-channel</i>."; |
911 | . "The format is <i>width</i> x <i>height</i> \@ <i>depth-per-channel</i> + <i>alpha-channel</i>."; |
900 | |
912 | |
… | |
… | |
2249 | DC::SDL_Init DC::SDL_INIT_AUDIO #| DC::SDL_NOPARACHUTE |
2261 | DC::SDL_Init DC::SDL_INIT_AUDIO #| DC::SDL_NOPARACHUTE |
2250 | and die "SDL::Init failed!\n"; |
2262 | and die "SDL::Init failed!\n"; |
2251 | } |
2263 | } |
2252 | |
2264 | |
2253 | sub video_init { |
2265 | sub video_init { |
|
|
2266 | DC::set_theme $CFG->{uitheme}; |
|
|
2267 | |
2254 | DC::SDL_InitSubSystem DC::SDL_INIT_VIDEO if $SDL_REINIT; |
2268 | DC::SDL_InitSubSystem DC::SDL_INIT_VIDEO if $SDL_REINIT; |
2255 | $SDL_REINIT = 0; |
2269 | $SDL_REINIT = 0; |
2256 | |
2270 | |
2257 | @SDL_MODES = DC::SDL_ListModes 8, $CFG->{disable_alpha} ? 0 : 8; |
2271 | @SDL_MODES = DC::SDL_ListModes 8, $CFG->{disable_alpha} ? 0 : 8; |
2258 | @SDL_MODES = DC::SDL_ListModes 8, 8 unless @SDL_MODES; |
2272 | @SDL_MODES = DC::SDL_ListModes 8, 8 unless @SDL_MODES; |
… | |
… | |
2639 | inv_sort => "mtime", |
2653 | inv_sort => "mtime", |
2640 | default => "profile", # default profile |
2654 | default => "profile", # default profile |
2641 | show_tips => 1, |
2655 | show_tips => 1, |
2642 | logview_max_par => 1000, |
2656 | logview_max_par => 1000, |
2643 | shift_fire_stop => 0, |
2657 | shift_fire_stop => 0, |
|
|
2658 | uitheme => "wood", |
2644 | ); |
2659 | ); |
2645 | |
2660 | |
2646 | while (my ($k, $v) = each %DEF_CFG) { |
2661 | while (my ($k, $v) = each %DEF_CFG) { |
2647 | $CFG->{$k} = $v unless exists $CFG->{$k}; |
2662 | $CFG->{$k} = $v unless exists $CFG->{$k}; |
2648 | } |
2663 | } |