-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrated the conan remote tab to a separated widget
- Loading branch information
Showing
9 changed files
with
338 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import os | ||
import pyperclip | ||
|
||
from PySide2 import QtWidgets | ||
from PySide2.QtCore import Slot | ||
|
||
from conanguide.api.conan_api import ConanApi | ||
from conanguide.ui.widget.tab.remote.tab_remote_ui import Ui_TabRemote | ||
|
||
from conanguide.ui.controller.tab.remote.conan_remote import ConanRemoteListController | ||
|
||
|
||
class TabRemote(QtWidgets.QWidget, Ui_TabRemote): | ||
def __init__(self, conan_api: ConanApi, *args, obj=None, **kwargs): | ||
super(TabRemote, self).__init__(*args, **kwargs) | ||
|
||
self.setupUi(self) | ||
|
||
self.conan_api = conan_api | ||
|
||
# Tableview initialization for the remote list | ||
self.ctrl_tableview_conan_remote = ConanRemoteListController(self.tableViewRemoteList, self.conan_api) | ||
self.ctrl_tableview_conan_remote.update() | ||
|
||
def refresh(self): | ||
# TODO: Implement refresh function. | ||
pass |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,162 @@ | ||
# -*- coding: utf-8 -*- | ||
|
||
################################################################################ | ||
## Form generated from reading UI file 'tab_remote.ui' | ||
## | ||
## Created by: Qt User Interface Compiler version 5.15.2 | ||
## | ||
## WARNING! All changes made in this file will be lost when recompiling UI file! | ||
################################################################################ | ||
|
||
from PySide2.QtCore import * | ||
from PySide2.QtGui import * | ||
from PySide2.QtWidgets import * | ||
|
||
from conanguide.ui.res import resources_rc | ||
|
||
class Ui_TabRemote(object): | ||
def setupUi(self, TabRemote): | ||
if not TabRemote.objectName(): | ||
TabRemote.setObjectName(u"TabRemote") | ||
TabRemote.resize(772, 652) | ||
self.verticalLayout = QVBoxLayout(TabRemote) | ||
self.verticalLayout.setSpacing(5) | ||
self.verticalLayout.setObjectName(u"verticalLayout") | ||
self.verticalLayout.setContentsMargins(0, 0, 0, 0) | ||
self.frame_7 = QFrame(TabRemote) | ||
self.frame_7.setObjectName(u"frame_7") | ||
self.frame_7.setFrameShape(QFrame.StyledPanel) | ||
self.frame_7.setFrameShadow(QFrame.Raised) | ||
self.horizontalLayout_16 = QHBoxLayout(self.frame_7) | ||
self.horizontalLayout_16.setSpacing(0) | ||
self.horizontalLayout_16.setObjectName(u"horizontalLayout_16") | ||
self.horizontalLayout_16.setContentsMargins(0, 0, 0, 0) | ||
self.toolButton = QToolButton(self.frame_7) | ||
self.toolButton.setObjectName(u"toolButton") | ||
self.toolButton.setMinimumSize(QSize(25, 25)) | ||
self.toolButton.setMaximumSize(QSize(20, 16777215)) | ||
icon = QIcon() | ||
icon.addFile(u":/icon/light/add.png", QSize(), QIcon.Normal, QIcon.Off) | ||
self.toolButton.setIcon(icon) | ||
|
||
self.horizontalLayout_16.addWidget(self.toolButton) | ||
|
||
self.toolButton_2 = QToolButton(self.frame_7) | ||
self.toolButton_2.setObjectName(u"toolButton_2") | ||
sizePolicy = QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed) | ||
sizePolicy.setHorizontalStretch(0) | ||
sizePolicy.setVerticalStretch(0) | ||
sizePolicy.setHeightForWidth(self.toolButton_2.sizePolicy().hasHeightForWidth()) | ||
self.toolButton_2.setSizePolicy(sizePolicy) | ||
self.toolButton_2.setMinimumSize(QSize(25, 25)) | ||
icon1 = QIcon() | ||
icon1.addFile(u":/icon/light/remove.png", QSize(), QIcon.Normal, QIcon.Off) | ||
self.toolButton_2.setIcon(icon1) | ||
|
||
self.horizontalLayout_16.addWidget(self.toolButton_2) | ||
|
||
self.horizontalSpacer_2 = QSpacerItem(40, 20, QSizePolicy.Expanding, QSizePolicy.Minimum) | ||
|
||
self.horizontalLayout_16.addItem(self.horizontalSpacer_2) | ||
|
||
|
||
self.verticalLayout.addWidget(self.frame_7) | ||
|
||
self.tableViewRemoteList = QTableView(TabRemote) | ||
self.tableViewRemoteList.setObjectName(u"tableViewRemoteList") | ||
self.tableViewRemoteList.setHorizontalScrollMode(QAbstractItemView.ScrollPerPixel) | ||
|
||
self.verticalLayout.addWidget(self.tableViewRemoteList) | ||
|
||
|
||
self.retranslateUi(TabRemote) | ||
|
||
QMetaObject.connectSlotsByName(TabRemote) | ||
# setupUi | ||
|
||
def retranslateUi(self, TabRemote): | ||
TabRemote.setWindowTitle(QCoreApplication.translate("TabRemote", u"Form", None)) | ||
self.toolButton.setText("") | ||
self.toolButton_2.setText("") | ||
# re# -*- coding: utf-8 -*- | ||
|
||
################################################################################ | ||
## Form generated from reading UI file 'tab_remote.ui' | ||
## | ||
## Created by: Qt User Interface Compiler version 5.15.2 | ||
## | ||
## WARNING! All changes made in this file will be lost when recompiling UI file! | ||
################################################################################ | ||
|
||
from PySide2.QtCore import * | ||
from PySide2.QtGui import * | ||
from PySide2.QtWidgets import * | ||
|
||
from conanguide.ui.res import resources_rc | ||
|
||
class Ui_TabRemote(object): | ||
def setupUi(self, TabRemote): | ||
if not TabRemote.objectName(): | ||
TabRemote.setObjectName(u"TabRemote") | ||
TabRemote.resize(772, 652) | ||
self.verticalLayout = QVBoxLayout(TabRemote) | ||
self.verticalLayout.setSpacing(5) | ||
self.verticalLayout.setObjectName(u"verticalLayout") | ||
self.verticalLayout.setContentsMargins(0, 0, 0, 0) | ||
self.frame_7 = QFrame(TabRemote) | ||
self.frame_7.setObjectName(u"frame_7") | ||
self.frame_7.setFrameShape(QFrame.StyledPanel) | ||
self.frame_7.setFrameShadow(QFrame.Raised) | ||
self.horizontalLayout_16 = QHBoxLayout(self.frame_7) | ||
self.horizontalLayout_16.setSpacing(0) | ||
self.horizontalLayout_16.setObjectName(u"horizontalLayout_16") | ||
self.horizontalLayout_16.setContentsMargins(0, 0, 0, 0) | ||
self.toolButton = QToolButton(self.frame_7) | ||
self.toolButton.setObjectName(u"toolButton") | ||
self.toolButton.setMinimumSize(QSize(25, 25)) | ||
self.toolButton.setMaximumSize(QSize(20, 16777215)) | ||
icon = QIcon() | ||
icon.addFile(u":/icon/light/add.png", QSize(), QIcon.Normal, QIcon.Off) | ||
self.toolButton.setIcon(icon) | ||
|
||
self.horizontalLayout_16.addWidget(self.toolButton) | ||
|
||
self.toolButton_2 = QToolButton(self.frame_7) | ||
self.toolButton_2.setObjectName(u"toolButton_2") | ||
sizePolicy = QSizePolicy(QSizePolicy.Fixed, QSizePolicy.Fixed) | ||
sizePolicy.setHorizontalStretch(0) | ||
sizePolicy.setVerticalStretch(0) | ||
sizePolicy.setHeightForWidth(self.toolButton_2.sizePolicy().hasHeightForWidth()) | ||
self.toolButton_2.setSizePolicy(sizePolicy) | ||
self.toolButton_2.setMinimumSize(QSize(25, 25)) | ||
icon1 = QIcon() | ||
icon1.addFile(u":/icon/light/remove.png", QSize(), QIcon.Normal, QIcon.Off) | ||
self.toolButton_2.setIcon(icon1) | ||
|
||
self.horizontalLayout_16.addWidget(self.toolButton_2) | ||
|
||
self.horizontalSpacer_2 = QSpacerItem(40, 20, QSizePolicy.Expanding, QSizePolicy.Minimum) | ||
|
||
self.horizontalLayout_16.addItem(self.horizontalSpacer_2) | ||
|
||
|
||
self.verticalLayout.addWidget(self.frame_7) | ||
|
||
self.tableViewRemoteList = QTableView(TabRemote) | ||
self.tableViewRemoteList.setObjectName(u"tableViewRemoteList") | ||
self.tableViewRemoteList.setHorizontalScrollMode(QAbstractItemView.ScrollPerPixel) | ||
|
||
self.verticalLayout.addWidget(self.tableViewRemoteList) | ||
|
||
|
||
self.retranslateUi(TabRemote) | ||
|
||
QMetaObject.connectSlotsByName(TabRemote) | ||
# setupUi | ||
|
||
def retranslateUi(self, TabRemote): | ||
TabRemote.setWindowTitle(QCoreApplication.translate("TabRemote", u"Form", None)) | ||
self.toolButton.setText("") | ||
self.toolButton_2.setText("") | ||
# retranslateUi | ||
|
Oops, something went wrong.