Skip to content

Commit

Permalink
Polish and bump up to version 1.0!
Browse files Browse the repository at this point in the history
  • Loading branch information
grossmj committed Oct 21, 2014
1 parent 534cff6 commit 2943a4e
Show file tree
Hide file tree
Showing 9 changed files with 34 additions and 16 deletions.
2 changes: 1 addition & 1 deletion gns3/console_view.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ def __init__(self, parent):

# Set introduction message
bitness = struct.calcsize("P") * 8
self.intro = "GNS3 management console. Running GNS3 Early Release (ER) version {} on {} ({}-bit).\n" \
self.intro = "GNS3 management console. Running GNS3 version {} on {} ({}-bit).\n" \
"Copyright (c) 2006-2014 GNS3 Technologies.".format(__version__, platform.system(), bitness)

# Parent class initialization
Expand Down
5 changes: 5 additions & 0 deletions gns3/dialogs/new_project_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.

import os
import shutil
from ..qt import QtCore, QtGui
from ..ui.new_project_dialog_ui import Ui_NewProjectDialog

Expand Down Expand Up @@ -98,4 +99,8 @@ def done(self, result):
self._project_settings["project_path"] = os.path.join(project_location, project_name + ".gns3")
self._project_settings["project_files_dir"] = os.path.join(project_location, project_name + "-files")
self._project_settings["project_type"] = project_type

# delete all the project files
shutil.rmtree(self._project_settings["project_files_dir"], ignore_errors=True)

QtGui.QDialog.done(self, result)
2 changes: 1 addition & 1 deletion gns3/dialogs/preferences_dialog.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def _loadPreferencePages(self):
GeneralPreferencesPage,
ServerPreferencesPage,
PacketCapturePreferencesPage,
CloudPreferencesPage,
#CloudPreferencesPage,
]

for page in pages:
Expand Down
6 changes: 3 additions & 3 deletions gns3/main_window.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,8 @@ def __init__(self, parent=None):
# set the window icon
self.setWindowIcon(QtGui.QIcon(":/images/gns3.ico"))

#FIXME: hide the cloud dock for beta release
# self.uiCloudInspectorDockWidget.hide()
#FIXME: hide the cloud dock for release
self.uiCloudInspectorDockWidget.hide()

# Network Manager (used to check for update)
self._network_manager = QtNetwork.QNetworkAccessManager(self)
Expand Down Expand Up @@ -839,7 +839,7 @@ def _gettingStartedActionSlot(self, auto=False):

dialog = GettingStartedDialog(self)
dialog.showit()
if auto is True and not dialog.showit():
if auto is True and dialog.showit():
return
dialog.show()
dialog.exec_()
Expand Down
2 changes: 1 addition & 1 deletion gns3/modules/iou/dialogs/iou_device_wizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -167,7 +167,7 @@ def getSettings(self):
hover_symbol = ":/symbols/router.selected.svg"
category = Node.routers

if IOU.instance().settings()["use_local_server"] or self.uiLoadBalanceCheckBox.isChecked():
if IOU.instance().settings()["use_local_server"] or self.uiLocalRadioButton.isChecked():
server = "local"
elif self.uiLoadBalanceCheckBox.isChecked():
server = next(iter(Servers.instance()))
Expand Down
17 changes: 13 additions & 4 deletions gns3/modules/qemu/dialogs/qemu_vm_wizard.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
Wizard for QEMU VMs.
"""

import sys
import os
import shutil

Expand Down Expand Up @@ -232,10 +233,18 @@ def _getQemuBinariesFromServerCallback(self, result, error=False):
else:
self.uiQemuListComboBox.clear()
for qemu in result["qemus"]:
self.uiQemuListComboBox.addItem("{path} (v{version})".format(path=qemu["path"], version=qemu["version"]), qemu["path"])

# default is qemu-system-x86_64
index = self.uiQemuListComboBox.findText("x86_64 ", QtCore.Qt.MatchContains) # the space after x86_64 must be present!
if qemu["version"]:
self.uiQemuListComboBox.addItem("{path} (v{version})".format(path=qemu["path"], version=qemu["version"]), qemu["path"])
else:
self.uiQemuListComboBox.addItem("{path}".format(path=qemu["path"]), qemu["path"])

#FIXME: use findData instead
if sys.platform.startswith("win"):
# default is qemu-system-x86_64w on Windows
index = self.uiQemuListComboBox.findText("x86_64w", QtCore.Qt.MatchContains)
else:
# default is qemu-system-x86_64 on other platforms
index = self.uiQemuListComboBox.findText("x86_64 ", QtCore.Qt.MatchContains) # the space after x86_64 must be present!
if index != -1:
self.uiQemuListComboBox.setCurrentIndex(index)

Expand Down
7 changes: 5 additions & 2 deletions gns3/ui/new_project_dialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>622</width>
<height>202</height>
<width>472</width>
<height>175</height>
</rect>
</property>
<property name="windowTitle">
Expand All @@ -20,6 +20,9 @@
<bool>true</bool>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<property name="sizeConstraint">
<enum>QLayout::SetFixedSize</enum>
</property>
<item row="1" column="0">
<widget class="QDialogButtonBox" name="uiButtonBox">
<property name="orientation">
Expand Down
5 changes: 3 additions & 2 deletions gns3/ui/new_project_dialog_ui.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

# Form implementation generated from reading ui file '/home/grossmj/PycharmProjects/gns3-gui/gns3/ui/new_project_dialog.ui'
#
# Created: Thu Oct 16 22:18:42 2014
# Created: Mon Oct 20 16:31:02 2014
# by: PyQt4 UI code generator 4.10.4
#
# WARNING! All changes made in this file will be lost!
Expand All @@ -27,9 +27,10 @@ class Ui_NewProjectDialog(object):
def setupUi(self, NewProjectDialog):
NewProjectDialog.setObjectName(_fromUtf8("NewProjectDialog"))
NewProjectDialog.setWindowModality(QtCore.Qt.ApplicationModal)
NewProjectDialog.resize(622, 202)
NewProjectDialog.resize(472, 175)
NewProjectDialog.setModal(True)
self.gridLayout_2 = QtGui.QGridLayout(NewProjectDialog)
self.gridLayout_2.setSizeConstraint(QtGui.QLayout.SetFixedSize)
self.gridLayout_2.setObjectName(_fromUtf8("gridLayout_2"))
self.uiButtonBox = QtGui.QDialogButtonBox(NewProjectDialog)
self.uiButtonBox.setOrientation(QtCore.Qt.Horizontal)
Expand Down
4 changes: 2 additions & 2 deletions gns3/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@
number has been incremented)
"""

__version__ = "1.0.dev1"
__version_info__ = (1, 0, 0, -99)
__version__ = "1.0"
__version_info__ = (1, 0, 0, 0)

0 comments on commit 2943a4e

Please sign in to comment.