[app] change imports to package imports
This commit is contained in:
parent
a1bfbb8fe7
commit
c5336de226
@ -3,11 +3,11 @@ from PyQt5.QtWidgets import QComboBox, QFrame, QGroupBox, QHBoxLayout, QLabel, Q
|
|||||||
from PyQt5.QtGui import QPixmap
|
from PyQt5.QtGui import QPixmap
|
||||||
from PyQt5.QtCore import QItemSelectionModel, Qt, QSettings, pyqtSignal
|
from PyQt5.QtCore import QItemSelectionModel, Qt, QSettings, pyqtSignal
|
||||||
|
|
||||||
from file_handler import FileHandler, ItemDescriptor
|
from nixview.file_handler import FileHandler, ItemDescriptor
|
||||||
from plot_screen import PlotScreen
|
from nixview.plot_screen import PlotScreen
|
||||||
import communicator as comm
|
import nixview.communicator as comm
|
||||||
import constants as cnst
|
import nixview.constants as cnst
|
||||||
from tree_model import NixTreeView, TreeModel, TreeType
|
from nixview.tree_model import NixTreeView, TreeModel, TreeType
|
||||||
|
|
||||||
class CentralWidget(QWidget):
|
class CentralWidget(QWidget):
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
from tree_model import NixTreeItem
|
from nixview.tree_model import NixTreeItem
|
||||||
from PyQt5.QtCore import QObject, pyqtSignal
|
from PyQt5.QtCore import QObject, pyqtSignal
|
||||||
|
|
||||||
class Communicate(QObject):
|
class Communicate(QObject):
|
||||||
|
@ -1,7 +1,12 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
organization = "nixio"
|
organization = "nixio"
|
||||||
application = "nixview"
|
application = "nixview"
|
||||||
version = 0.1
|
version = 0.1
|
||||||
|
|
||||||
settings_recent_files_key = "/".join([organization, application, "recent_files"])
|
settings_recent_files_key = "/".join([organization, application, "recent_files"])
|
||||||
settings_recent_file_max_count_key = "/".join([organization, application, "recent_files_max_count"])
|
settings_recent_file_max_count_key = "/".join([organization, application, "recent_files_max_count"])
|
||||||
settings_recent_file_max_count = 10
|
settings_recent_file_max_count = 10
|
||||||
|
|
||||||
|
PACKAGE_ROOT = os.path.abspath(os.path.join(os.path.dirname(__file__), os.pardir))
|
||||||
|
ICONS_FOLDER = os.path.join(PACKAGE_ROOT, "icons")
|
||||||
|
@ -3,10 +3,11 @@ from PyQt5.QtWidgets import QWidget, QFileDialog, QMainWindow, QMenuBar, QToolBa
|
|||||||
from PyQt5.QtGui import QIcon, QKeySequence
|
from PyQt5.QtGui import QIcon, QKeySequence
|
||||||
from PyQt5.QtCore import QSize, QSettings, Qt
|
from PyQt5.QtCore import QSize, QSettings, Qt
|
||||||
|
|
||||||
from file_handler import FileHandler, NodeType
|
from nixview.file_handler import FileHandler, NodeType
|
||||||
import constants as cnst
|
import nixview.constants as cnst
|
||||||
import communicator as comm
|
import nixview.communicator as comm
|
||||||
from central_widget import CentralWidget
|
from nixview.central_widget import CentralWidget
|
||||||
|
|
||||||
|
|
||||||
class NixView(QMainWindow):
|
class NixView(QMainWindow):
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/python3
|
#!/usr/bin/python3
|
||||||
import sys
|
import sys
|
||||||
from PyQt5.QtWidgets import QApplication
|
from PyQt5.QtWidgets import QApplication
|
||||||
from main_window import NixView
|
from nixview.main_window import NixView
|
||||||
import argparse
|
import argparse
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
@ -3,7 +3,7 @@ from PyQt5.QtGui import QIcon
|
|||||||
from PyQt5.QtWidgets import QTreeView, QTreeWidgetItem, QAbstractItemView, QHeaderView
|
from PyQt5.QtWidgets import QTreeView, QTreeWidgetItem, QAbstractItemView, QHeaderView
|
||||||
from enum import Enum
|
from enum import Enum
|
||||||
|
|
||||||
from file_handler import ItemDescriptor, NodeType
|
from nixview.file_handler import ItemDescriptor, NodeType
|
||||||
|
|
||||||
column_names = ['Name', 'Type', 'Value', 'Description', 'ID',]
|
column_names = ['Name', 'Type', 'Value', 'Description', 'ID',]
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user