Commit 49f0cd87 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Qt: OpenUrlDialog ain't a Singleton anymore

And remove unnecessary killInstances
parent af29c151
......@@ -34,12 +34,11 @@
class ClickLineEdit;
class OpenUrlDialog : public QVLCDialog, public Singleton<OpenUrlDialog>
class OpenUrlDialog : public QVLCDialog
{
Q_OBJECT
private:
OpenUrlDialog( intf_thread_t *, bool bClipboard = true );
QString lastUrl;
bool bClipboard, bShouldEnqueue;
ClickLineEdit *edit;
......@@ -49,6 +48,7 @@ private slots:
void play();
public:
OpenUrlDialog( intf_thread_t *, bool bClipboard = true );
virtual ~OpenUrlDialog() {}
QString url() const;
......@@ -58,7 +58,6 @@ public:
public slots:
virtual void close() { play(); };
friend class Singleton<OpenUrlDialog>;
};
#endif
......@@ -91,14 +91,10 @@ DialogsProvider::~DialogsProvider()
ExtendedDialog::killInstance();
BookmarksDialog::killInstance();
HelpDialog::killInstance();
AboutDialog::killInstance();
#ifdef UPDATE_CHECK
UpdateDialog::killInstance();
#endif
PluginDialog::killInstance();
VLMDialog::killInstance();
OpenUrlDialog::killInstance();
GotoTimeDialog::killInstance();
PodcastConfigDialog::killInstance();
EpgDialog::killInstance();
ErrorsDialog::killInstance();
......@@ -470,7 +466,7 @@ void DialogsProvider::simpleMLAppendDialog()
**/
void DialogsProvider::openUrlDialog()
{
OpenUrlDialog *oud = OpenUrlDialog::getInstance( p_intf );
OpenUrlDialog *oud = new OpenUrlDialog( p_intf );
if( oud->exec() == QDialog::Accepted )
{
QString url = oud->url();
......@@ -484,6 +480,7 @@ void DialogsProvider::openUrlDialog()
RecentsMRL::getInstance( p_intf )->addRecent( url );
}
}
delete oud;
}
/* Directory */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment