Set tooltip in instance of close button, not class.
Also set a similar tooltip for the previous and next buttons and comments for translators.
This commit is contained in:
@@ -252,12 +252,6 @@ public:
|
|||||||
SetExplicitMaxSize(BSize(15, 15));
|
SetExplicitMaxSize(BSize(15, 15));
|
||||||
}
|
}
|
||||||
|
|
||||||
virtual void AttachedToWindow()
|
|
||||||
{
|
|
||||||
SetToolTip(B_TRANSLATE("Close find bar"));
|
|
||||||
BButton::AttachedToWindow();
|
|
||||||
}
|
|
||||||
|
|
||||||
virtual void Draw(BRect updateRect)
|
virtual void Draw(BRect updateRect)
|
||||||
{
|
{
|
||||||
BRect frame = Bounds();
|
BRect frame = Bounds();
|
||||||
@@ -506,13 +500,21 @@ BrowserWindow::BrowserWindow(BRect frame, SettingsMessage* appSettings,
|
|||||||
|
|
||||||
// Find group
|
// Find group
|
||||||
fFindCloseButton = new CloseButton(new BMessage(EDIT_HIDE_FIND_GROUP));
|
fFindCloseButton = new CloseButton(new BMessage(EDIT_HIDE_FIND_GROUP));
|
||||||
|
fFindCloseButton->SetToolTip(B_TRANSLATE_COMMENT("Close find bar",
|
||||||
|
"find bar close button tooltip"));
|
||||||
fFindTextControl = new BTextControl("find", B_TRANSLATE("Find:"), "",
|
fFindTextControl = new BTextControl("find", B_TRANSLATE("Find:"), "",
|
||||||
new BMessage(EDIT_FIND_NEXT));
|
new BMessage(EDIT_FIND_NEXT));
|
||||||
fFindTextControl->SetModificationMessage(new BMessage(FIND_TEXT_CHANGED));
|
fFindTextControl->SetModificationMessage(new BMessage(FIND_TEXT_CHANGED));
|
||||||
fFindPreviousButton = new BButton(B_TRANSLATE("Previous"),
|
fFindPreviousButton = new BButton(B_TRANSLATE("Previous"),
|
||||||
new BMessage(EDIT_FIND_PREVIOUS));
|
new BMessage(EDIT_FIND_PREVIOUS));
|
||||||
|
fFindPreviousButton->SetToolTip(
|
||||||
|
B_TRANSLATE_COMMENT("Find previous occurrence of search terms",
|
||||||
|
"find bar previous button tooltip"));
|
||||||
fFindNextButton = new BButton(B_TRANSLATE("Next"),
|
fFindNextButton = new BButton(B_TRANSLATE("Next"),
|
||||||
new BMessage(EDIT_FIND_NEXT));
|
new BMessage(EDIT_FIND_NEXT));
|
||||||
|
fFindNextButton->SetToolTip(
|
||||||
|
B_TRANSLATE_COMMENT("Find next occurrence of search terms",
|
||||||
|
"find bar next button tooltip"));
|
||||||
fFindCaseSensitiveCheckBox = new BCheckBox(B_TRANSLATE("Match case"));
|
fFindCaseSensitiveCheckBox = new BCheckBox(B_TRANSLATE("Match case"));
|
||||||
BGroupLayout* findGroup = BLayoutBuilder::Group<>(B_VERTICAL, 0.0)
|
BGroupLayout* findGroup = BLayoutBuilder::Group<>(B_VERTICAL, 0.0)
|
||||||
.Add(new BSeparatorView(B_HORIZONTAL, B_PLAIN_BORDER))
|
.Add(new BSeparatorView(B_HORIZONTAL, B_PLAIN_BORDER))
|
||||||
|
|||||||
Reference in New Issue
Block a user