There is no more "default" fortune file.
Instead, let's call /bin/fortune without specific file by default to use its random selection feature. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30310 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -27,7 +27,7 @@ ConfigView::ConfigView()
|
|||||||
|
|
||||||
BRect rect(5,4,250,25);
|
BRect rect(5,4,250,25);
|
||||||
rect.bottom = rect.top - 2 + itemHeight;
|
rect.bottom = rect.top - 2 + itemHeight;
|
||||||
BMailFileConfigView *fview = new BMailFileConfigView(MDR_DIALECT_CHOICE ("Fortune File:","予言ファイル:"),"fortune_file",false,"/boot/system/etc/fortunes/default",B_FILE_NODE);
|
BMailFileConfigView *fview = new BMailFileConfigView(MDR_DIALECT_CHOICE ("Fortune File:","予言ファイル:"),"fortune_file",false,"",B_FILE_NODE);
|
||||||
AddChild(fview);
|
AddChild(fview);
|
||||||
|
|
||||||
rect.top = rect.bottom + 8;
|
rect.top = rect.bottom + 8;
|
||||||
@@ -42,14 +42,10 @@ ConfigView::ConfigView()
|
|||||||
|
|
||||||
void ConfigView::SetTo(BMessage *archive)
|
void ConfigView::SetTo(BMessage *archive)
|
||||||
{
|
{
|
||||||
BString path = archive->FindString("fortune_file");
|
|
||||||
if (path == B_EMPTY_STRING)
|
|
||||||
path = "/boot/system/etc/fortunes/default";
|
|
||||||
|
|
||||||
if (BMailFileConfigView *control = (BMailFileConfigView *)FindView("fortune_file"))
|
if (BMailFileConfigView *control = (BMailFileConfigView *)FindView("fortune_file"))
|
||||||
control->SetTo(archive,NULL);
|
control->SetTo(archive,NULL);
|
||||||
|
|
||||||
path = archive->FindString("tag_line");
|
BString path = archive->FindString("tag_line");
|
||||||
if (!archive->HasString("tag_line"))
|
if (!archive->HasString("tag_line"))
|
||||||
path = "Fortune Cookie Says:\n\n";
|
path = "Fortune Cookie Says:\n\n";
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user