Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fix wrong video_driver setting when changing in mainmenu
Fixes issue with direct3d(8|9)
  • Loading branch information
SmallJoker authored and BlockMen committed Sep 21, 2014
1 parent 406ed5e commit 44a1d0c
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions builtin/mainmenu/tab_settings.lua
Expand Up @@ -122,7 +122,8 @@ local function formspec(tabview, name, tabdata)
end
video_driver_string = video_driver_string .. video_drivers[i]

if current_video_driver:lower() == video_drivers[i]:lower() then
local video_driver = string.gsub(video_drivers[i], " ", "")
if current_video_driver:lower() == video_driver:lower() then
current_video_driver_idx = i
end
end
Expand Down Expand Up @@ -317,7 +318,8 @@ local function handle_settings_buttons(this, fields, tabname, tabdata)
ddhandled = true
end
if fields["dd_video_driver"] then
core.setting_set("video_driver",fields["dd_video_driver"])
local video_driver = string.gsub(fields["dd_video_driver"], " ", "")
core.setting_set("video_driver",string.lower(video_driver))
ddhandled = true
end

Expand Down

0 comments on commit 44a1d0c

Please sign in to comment.