Dialog Slider not showing default value

Case number:845813-991321
Topic:Game: Tools
Opened by:bertro
Status:Closed
Type:Bug
Opened on:Saturday, December 17, 2011 - 21:45
Last modified:Thursday, December 29, 2011 - 17:39

In LUA v2, the dialog slider object (integer or decimal):

1) does not initially show a default value unless the default value is bigger than the minimum value. If you move the slider a bit, the value will appear. See attached file...

2) the left and right arrows are not working.

AttachmentSize
Test Dialog ouput.png68.4 KB
(Sat, 12/17/2011 - 21:45  |  5 comments)


Joined: 06/17/2010

Plz post code you have used to create it.

bertro's picture
User offline. Last seen 12 hours 45 min ago. Offline
Joined: 05/02/2011
Groups: Beta Folders

Here is the code:

function AskVerbose()
local ask = dialog.CreateDialog("Test Dialog")
ask.Instructions = dialog.AddLabel("Set these values:")
ask.Invert = dialog.AddCheckbox("Invert", true)
ask.Iterations = dialog.AddSlider("Iterations", 1, 1, 25, 0) -- (default, min, max, 1=Int/0=Decimal)
ask.Iterations1 = dialog.AddSlider("Iterations1", 2, 2, 25, 0) -- (default, min, max, 1=Int/0=Decimal)
ask.Iterations2 = dialog.AddSlider("Iterations2", 1, 0, 25, 0) -- (default, min, max, 1=Int/0=Decimal)
ask.BandStrength = dialog.AddSlider("Band Strength", 5.3, 0.1, 10.0, 1) -- (default, min, max, 1=Int/0=Decimal)
ask.BandStrength1 = dialog.AddSlider("Band Strength1", 0.1, 0.1, 10.0, 1) -- (default, min, max, 1=Int/0=Decimal)
ask.Comment = dialog.AddTextbox("Comment", "Cool!")
ask.OK = dialog.AddButton("OK", 1)
ask.Cancel = dialog.AddButton("Cancel", 0)
if (dialog.Show(ask) > 0) then
Verbose = true
local tell = dialog.CreateDialog("Test Dialog Results")
if (ask.Invert.value) then
tell.Invert = dialog.AddLabel("Invert=true")
else
tell.Invert = dialog.AddLabel("Invert=false")
end
tell.Iterations = dialog.AddLabel("Iterations="..ask.Iterations.value)
tell.BandStrength = dialog.AddLabel("Band Strength="..ask.BandStrength.value)
tell.Comment = dialog.AddLabel("Comment="..ask.Comment.value)
tell.OK = dialog.AddButton("OK", 1)
dialog.Show(tell)
else
Verbose = false
print("Dialog cancelled")
end
end

AskVerbose()

Joined: 11/10/2007
Groups: Window Group
Status: Open » Closed

This will be fixed in the next update.

bertro's picture
User offline. Last seen 12 hours 45 min ago. Offline
Joined: 05/02/2011
Groups: Beta Folders

Thanks

Joined: 11/10/2007
Groups: Window Group
Topic: Developer Preview » Game: Tools
Status: Closed » Closed

This should be out in a recent update.

Sitemap

Developed by: UW Center for Game Science, UW Institute for Protein Design, Northeastern University, Vanderbilt University Meiler Lab, UC Davis
Supported by: DARPA, NSF, NIH, HHMI, Amazon, Microsoft, Adobe, RosettaCommons