File tree Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Expand file tree Collapse file tree 2 files changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -48,16 +48,16 @@ void displayOptions( const std::vector<avtranscoder::Option>& options )
48
48
std::cout << " Default choice index: " << option.getDefaultChildIndex () << std::endl;
49
49
for (size_t i = 0 ; i < option.getChilds ().size (); ++i )
50
50
std::cout << " Choice " << i << " : " <<
51
- option.getChild ( i ).getName () << " // " <<
52
- option.getChild ( i ).getHelp () << std::endl;
51
+ option.getChildAtIndex ( i ).getName () << " // " <<
52
+ option.getChildAtIndex ( i ).getHelp () << std::endl;
53
53
}
54
54
else if ( option.getType () == avtranscoder::eOptionBaseTypeGroup )
55
55
{
56
56
std::cout << " Nb choices: " << option.getChilds ().size () << std::endl;
57
57
for (size_t i = 0 ; i < option.getChilds ().size (); ++i )
58
58
std::cout << " Element " << i << " : " <<
59
- option.getChild ( i ).getName () << " // " <<
60
- option.getChild ( i ).getDefaultValueBool () << std::endl;
59
+ option.getChildAtIndex ( i ).getName () << " // " <<
60
+ option.getChildAtIndex ( i ).getDefaultValueBool () << std::endl;
61
61
}
62
62
}
63
63
}
Original file line number Diff line number Diff line change @@ -73,7 +73,7 @@ class Option
73
73
// array of childs
74
74
bool hasChild () const { return ! _childOptions.empty (); }
75
75
const std::vector<Option>& getChilds () { return _childOptions; }
76
- const Option& getChild ( size_t index ) { return _childOptions.at ( index ); }
76
+ const Option& getChildAtIndex ( const size_t index ) const { return _childOptions.at ( index ); }
77
77
int getDefaultChildIndex () const { return _defaultChildIndex; }
78
78
79
79
void setDefaultChildIndex ( size_t index ) { _defaultChildIndex = index; }
You can’t perform that action at this time.
0 commit comments