Skip to content

Commit 9306529

Browse files
committed
Merge branch 'development-juce8' into testing-juce8
2 parents 661c0de + 7373fdd commit 9306529

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Source/Processors/Parameter/Parameter.cpp

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1198,7 +1198,9 @@ PathParameter::PathParameter (ParameterOwner* owner,
11981198
isDirectory (isDirectory_),
11991199
isRequired (isRequired_)
12001200
{
1201-
currentValue = defaultValue;
1201+
currentValue = "None";
1202+
if (isRequired)
1203+
currentValue = defaultValue;
12021204
}
12031205

12041206
void PathParameter::setNextValue (var newValue_, bool undoable)
@@ -1248,7 +1250,10 @@ bool PathParameter::isValid()
12481250
{
12491251
if (currentValue.toString() == "default")
12501252
{
1251-
currentValue = defaultValue;
1253+
if (isRequired)
1254+
currentValue = defaultValue;
1255+
else
1256+
currentValue = "None";
12521257
return true;
12531258
}
12541259
else if (! isDirectory && File (currentValue.toString()).existsAsFile())

0 commit comments

Comments
 (0)