Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
Donald Haase
Cockatrice
Commits
e1c5f4d4
Commit
e1c5f4d4
authored
Nov 09, 2014
by
Gavin Bisesi
Browse files
Merge pull request #419 from ctrlaltca/oracle_url
Oracle: add button to restore default download url
parents
13f6da15
cb055055
Changes
2
Hide whitespace changes
Inline
Side-by-side
oracle/src/oraclewizard.cpp
View file @
e1c5f4d4
...
@@ -103,17 +103,21 @@ LoadSetsPage::LoadSetsPage(QWidget *parent)
...
@@ -103,17 +103,21 @@ LoadSetsPage::LoadSetsPage(QWidget *parent)
urlRadioButton
->
setChecked
(
true
);
urlRadioButton
->
setChecked
(
true
);
urlButton
=
new
QPushButton
(
tr
(
"Restore default url"
),
this
);
connect
(
urlButton
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
actRestoreDefaultUrl
()));
fileButton
=
new
QPushButton
(
tr
(
"Choose file..."
),
this
);
fileButton
=
new
QPushButton
(
tr
(
"Choose file..."
),
this
);
connect
(
fileButton
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
actLoadSetsFile
()));
connect
(
fileButton
,
SIGNAL
(
clicked
()),
this
,
SLOT
(
actLoadSetsFile
()));
QGridLayout
*
layout
=
new
QGridLayout
(
this
);
QGridLayout
*
layout
=
new
QGridLayout
(
this
);
layout
->
addWidget
(
urlRadioButton
,
0
,
0
);
layout
->
addWidget
(
urlRadioButton
,
0
,
0
);
layout
->
addWidget
(
urlLineEdit
,
0
,
1
);
layout
->
addWidget
(
urlLineEdit
,
0
,
1
);
layout
->
addWidget
(
fileRadioButton
,
1
,
0
);
layout
->
addWidget
(
urlButton
,
1
,
1
,
Qt
::
AlignRight
);
layout
->
addWidget
(
fileLineEdit
,
1
,
1
);
layout
->
addWidget
(
fileRadioButton
,
2
,
0
);
layout
->
addWidget
(
fileButton
,
2
,
1
,
Qt
::
AlignRight
);
layout
->
addWidget
(
fileLineEdit
,
2
,
1
);
layout
->
addWidget
(
progressLabel
,
3
,
0
);
layout
->
addWidget
(
fileButton
,
3
,
1
,
Qt
::
AlignRight
);
layout
->
addWidget
(
progressBar
,
3
,
1
);
layout
->
addWidget
(
progressLabel
,
4
,
0
);
layout
->
addWidget
(
progressBar
,
4
,
1
);
connect
(
&
watcher
,
SIGNAL
(
finished
()),
this
,
SLOT
(
importFinished
()));
connect
(
&
watcher
,
SIGNAL
(
finished
()),
this
,
SLOT
(
importFinished
()));
...
@@ -128,6 +132,11 @@ void LoadSetsPage::initializePage()
...
@@ -128,6 +132,11 @@ void LoadSetsPage::initializePage()
progressBar
->
hide
();
progressBar
->
hide
();
}
}
void
LoadSetsPage
::
actRestoreDefaultUrl
()
{
urlLineEdit
->
setText
(
ALLSETS_URL
);
}
void
LoadSetsPage
::
actLoadSetsFile
()
void
LoadSetsPage
::
actLoadSetsFile
()
{
{
QFileDialog
dialog
(
this
,
tr
(
"Load sets file"
));
QFileDialog
dialog
(
this
,
tr
(
"Load sets file"
));
...
...
oracle/src/oraclewizard.h
View file @
e1c5f4d4
...
@@ -63,6 +63,7 @@ private:
...
@@ -63,6 +63,7 @@ private:
QRadioButton
*
fileRadioButton
;
QRadioButton
*
fileRadioButton
;
QLineEdit
*
urlLineEdit
;
QLineEdit
*
urlLineEdit
;
QLineEdit
*
fileLineEdit
;
QLineEdit
*
fileLineEdit
;
QPushButton
*
urlButton
;
QPushButton
*
fileButton
;
QPushButton
*
fileButton
;
QLabel
*
progressLabel
;
QLabel
*
progressLabel
;
QProgressBar
*
progressBar
;
QProgressBar
*
progressBar
;
...
@@ -72,6 +73,7 @@ private:
...
@@ -72,6 +73,7 @@ private:
QFuture
<
bool
>
future
;
QFuture
<
bool
>
future
;
private
slots
:
private
slots
:
void
actLoadSetsFile
();
void
actLoadSetsFile
();
void
actRestoreDefaultUrl
();
void
actDownloadProgressSetsFile
(
qint64
received
,
qint64
total
);
void
actDownloadProgressSetsFile
(
qint64
received
,
qint64
total
);
void
actDownloadFinishedSetsFile
();
void
actDownloadFinishedSetsFile
();
void
importFinished
();
void
importFinished
();
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment