Mail: properly disable prev/next buttons without Tracker.
* The prev/next buttons will only work when invoked via an actual mail file from Tracker.
This commit is contained in:
@@ -686,9 +686,10 @@ TMailWindow::BuildToolBar()
|
|||||||
B_TRANSLATE("Print"));
|
B_TRANSLATE("Print"));
|
||||||
fToolBar->AddAction(M_DELETE_NEXT, this, _RetrieveVectorIcon(4), NULL,
|
fToolBar->AddAction(M_DELETE_NEXT, this, _RetrieveVectorIcon(4), NULL,
|
||||||
B_TRANSLATE("Trash"));
|
B_TRANSLATE("Trash"));
|
||||||
if (fApp->ShowSpamGUI())
|
if (fApp->ShowSpamGUI()) {
|
||||||
fToolBar->AddAction(M_SPAM_BUTTON, this, _RetrieveVectorIcon(10), NULL,
|
fToolBar->AddAction(M_SPAM_BUTTON, this, _RetrieveVectorIcon(10),
|
||||||
B_TRANSLATE("Spam"));
|
NULL, B_TRANSLATE("Spam"));
|
||||||
|
}
|
||||||
fToolBar->AddSeparator();
|
fToolBar->AddSeparator();
|
||||||
fToolBar->AddAction(M_NEXTMSG, this, _RetrieveVectorIcon(6), NULL,
|
fToolBar->AddAction(M_NEXTMSG, this, _RetrieveVectorIcon(6), NULL,
|
||||||
B_TRANSLATE("Next"));
|
B_TRANSLATE("Next"));
|
||||||
@@ -701,6 +702,11 @@ TMailWindow::BuildToolBar()
|
|||||||
fToolBar->AddAction(M_PREVMSG, this, _RetrieveVectorIcon(7), NULL,
|
fToolBar->AddAction(M_PREVMSG, this, _RetrieveVectorIcon(7), NULL,
|
||||||
B_TRANSLATE("Previous"));
|
B_TRANSLATE("Previous"));
|
||||||
|
|
||||||
|
if (!fTrackerMessenger.IsValid()) {
|
||||||
|
fToolBar->SetActionEnabled(M_NEXTMSG, false);
|
||||||
|
fToolBar->SetActionEnabled(M_PREVMSG, false);
|
||||||
|
}
|
||||||
|
|
||||||
if (!fAutoMarkRead)
|
if (!fAutoMarkRead)
|
||||||
_AddReadButton();
|
_AddReadButton();
|
||||||
}
|
}
|
||||||
@@ -950,11 +956,6 @@ TMailWindow::MenusBeginning()
|
|||||||
} else {
|
} else {
|
||||||
fCut->SetEnabled(false);
|
fCut->SetEnabled(false);
|
||||||
fPaste->SetEnabled(false);
|
fPaste->SetEnabled(false);
|
||||||
|
|
||||||
if (!fTrackerMessenger.IsValid()) {
|
|
||||||
fNextMsg->SetEnabled(false);
|
|
||||||
fPrevMsg->SetEnabled(false);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user