* fix probable memory leaks, not in the image but anyway...
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@27851 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -136,6 +136,7 @@ SlideShowConfigView::SlideShowConfigView(const BRect &frame, const char *name,
|
|||||||
fFilePanel = new BFilePanel(B_OPEN_PANEL, NULL, (const entry_ref *) NULL,
|
fFilePanel = new BFilePanel(B_OPEN_PANEL, NULL, (const entry_ref *) NULL,
|
||||||
B_DIRECTORY_NODE, false, pMsg, NULL, true, true);
|
B_DIRECTORY_NODE, false, pMsg, NULL, true, true);
|
||||||
fFilePanel->SetButtonLabel(B_DEFAULT_BUTTON, "Select");
|
fFilePanel->SetButtonLabel(B_DEFAULT_BUTTON, "Select");
|
||||||
|
delete pMsg;
|
||||||
}
|
}
|
||||||
|
|
||||||
// ---------------------------------------------------------------
|
// ---------------------------------------------------------------
|
||||||
|
|||||||
@@ -246,7 +246,6 @@ UserPropertiesPanel::UserPropertiesPanel(BRect frame, const char *name, BWindow
|
|||||||
infoView = new UserPropertiesView(r, name == NULL ? NULL : user);
|
infoView = new UserPropertiesView(r, name == NULL ? NULL : user);
|
||||||
AddChild(infoView);
|
AddChild(infoView);
|
||||||
|
|
||||||
myMsgr = new BMessenger(NULL, this, NULL);
|
|
||||||
Show();
|
Show();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -264,7 +263,9 @@ void UserPropertiesPanel::MessageReceived(BMessage *msg)
|
|||||||
switch (msg->what)
|
switch (msg->what)
|
||||||
{
|
{
|
||||||
case MSG_USER_BROWSE:
|
case MSG_USER_BROWSE:
|
||||||
filePanel = new BFilePanel(B_OPEN_PANEL, myMsgr, &entryRef, B_DIRECTORY_NODE, false);
|
BMessenger messenger(this);
|
||||||
|
filePanel = new BFilePanel(B_OPEN_PANEL, &messenger, &entryRef,
|
||||||
|
B_DIRECTORY_NODE, false);
|
||||||
// filePanel->SetTarget(this);
|
// filePanel->SetTarget(this);
|
||||||
filePanel->Show();
|
filePanel->Show();
|
||||||
filePanel->Window()->SetTitle("User Home");
|
filePanel->Window()->SetTitle("User Home");
|
||||||
|
|||||||
@@ -58,7 +58,6 @@ class UserPropertiesPanel : public BWindow
|
|||||||
bool isCancelled() { return cancelled; }
|
bool isCancelled() { return cancelled; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
BMessenger *myMsgr;
|
|
||||||
UserPropertiesView *infoView;
|
UserPropertiesView *infoView;
|
||||||
BWindow *shareWin;
|
BWindow *shareWin;
|
||||||
char user[33];
|
char user[33];
|
||||||
|
|||||||
@@ -326,7 +326,9 @@ entry_ref ref;
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
fInputFilePanel = new BFilePanel(B_OPEN_PANEL, new BMessenger(this), NULL, B_FILE_NODE, false, msg);
|
BMessenger messenger(this)
|
||||||
|
fInputFilePanel = new BFilePanel(B_OPEN_PANEL, &messenger,
|
||||||
|
NULL, B_FILE_NODE, false, msg);
|
||||||
fInputFilePanel->Show();
|
fInputFilePanel->Show();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -375,7 +377,9 @@ entry_ref ref;
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
fOutputFilePanel = new BFilePanel(B_SAVE_PANEL, new BMessenger(this), NULL, B_FILE_NODE, false, msg);
|
BMessenger messenger(this)
|
||||||
|
fOutputFilePanel = new BFilePanel(B_SAVE_PANEL, &messenger,
|
||||||
|
NULL, B_FILE_NODE, false, msg);
|
||||||
fOutputFilePanel->Show();
|
fOutputFilePanel->Show();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -437,7 +441,9 @@ entry_ref ref;
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
fOutputFilePanel = new BFilePanel(B_OPEN_PANEL, new BMessenger(this), NULL, B_FILE_NODE, false, msg);
|
BMessenger messenger(this)
|
||||||
|
fOutputFilePanel = new BFilePanel(B_OPEN_PANEL, &messenger,
|
||||||
|
NULL, B_FILE_NODE, false, msg);
|
||||||
fOutputFilePanel->Show();
|
fOutputFilePanel->Show();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@@ -552,7 +558,9 @@ entry_ref ref;
|
|||||||
PostMessage(&message);
|
PostMessage(&message);
|
||||||
message = BMessage(*msg);
|
message = BMessage(*msg);
|
||||||
message.what = CHANGE_INPUT_FILE;
|
message.what = CHANGE_INPUT_FILE;
|
||||||
fInputFilePanel = fInputFilePanel = new BFilePanel(B_OPEN_PANEL, new BMessenger(this), NULL, B_FILE_NODE, false, msg);;
|
BMessenger messenger(this)
|
||||||
|
fInputFilePanel = new BFilePanel(B_OPEN_PANEL, &messenger,
|
||||||
|
NULL, B_FILE_NODE, false, msg);;
|
||||||
PostMessage(&message);
|
PostMessage(&message);
|
||||||
message = BMessage(OUTPUT_CHANGE_TO_BEOS_SYNTH);
|
message = BMessage(OUTPUT_CHANGE_TO_BEOS_SYNTH);
|
||||||
PostMessage(&message);
|
PostMessage(&message);
|
||||||
|
|||||||
@@ -107,9 +107,10 @@ ImageWindow::ImageWindow(BRect rect, const char *name)
|
|||||||
B_FOLLOW_ALL_SIDES, 0, true, true));
|
B_FOLLOW_ALL_SIDES, 0, true, true));
|
||||||
|
|
||||||
// Setup file open panel
|
// Setup file open panel
|
||||||
fpopenPanel = new BFilePanel(B_OPEN_PANEL, new BMessenger(this),
|
BMessenger messenger(this);
|
||||||
(const entry_ref *)NULL, 0L, false, new BMessage(M_OPEN_FILE_PANEL),
|
BMessage message(M_OPEN_FILE_PANEL);
|
||||||
NULL, false, true);
|
fpopenPanel = new BFilePanel(B_OPEN_PANEL, &messenger, NULL, 0L, false,
|
||||||
|
&message, NULL, false, true);
|
||||||
|
|
||||||
SetSizeLimits(200, 10000, 150, 10000);
|
SetSizeLimits(200, 10000, 150, 10000);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user