Tracker: Unchecked dynamic_cast in FilePanelPriv.cpp, CID 300327
This commit is contained in:
parent
e5355e2814
commit
a76808e72e
@ -1075,13 +1075,16 @@ TFilePanel::SetButtonLabel(file_panel_button selector, const char* text)
|
||||
void
|
||||
TFilePanel::SetSaveText(const char* text)
|
||||
{
|
||||
if (!text)
|
||||
if (text == NULL)
|
||||
return;
|
||||
|
||||
BTextControl* textControl
|
||||
= dynamic_cast<BTextControl*>(FindView("text view"));
|
||||
textControl->SetText(text);
|
||||
textControl->TextView()->SelectAll();
|
||||
if (textControl != NULL) {
|
||||
textControl->SetText(text);
|
||||
if (textControl->TextView() != NULL)
|
||||
textControl->TextView()->SelectAll();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user