Commit f2a7200c authored by Mark OLESEN's avatar Mark OLESEN
Browse files

STYLE: consistent lookupOrDefault template parameters

- in many cases can just use lookupOrDefault("key", bool) instead of
  lookupOrDefault<bool> or lookupOrDefault<Switch> since reading a
  bool from an Istream uses the Switch(Istream&) anyhow

STYLE: relocated Switch string names into file-local scope
parent f35115fb
......@@ -89,7 +89,7 @@ Foam::functionObjects::runTimePostPro::functionObjectBase::functionObjectBase
fieldVisualisationBase(dict, colours),
state_(state),
functionObjectName_(""),
clearObjects_(dict.lookupOrDefault<bool>("clearObjects", false))
clearObjects_(dict.lookupOrDefault("clearObjects", false))
{
dict.lookup("functionObject") >> functionObjectName_;
}
......
......@@ -49,7 +49,7 @@ Foam::functionObjects::runTimePostPro::text::text
size_(readScalar(dict.lookup("size"))),
colour_(nullptr),
bold_(readBool(dict.lookup("bold"))),
timeStamp_(dict.lookupOrDefault<bool>("timeStamp", false))
timeStamp_(dict.lookupOrDefault("timeStamp", false))
{
if (dict.found("colour"))
{
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment