mirror of
https://github.com/ynput/ayon-core.git
synced 2025-12-24 21:04:40 +01:00
initial commit of new tool
This commit is contained in:
parent
1456fa9c4e
commit
640b68b89c
2 changed files with 36 additions and 0 deletions
10
openpype/tools/context_dialog/__init__.py
Normal file
10
openpype/tools/context_dialog/__init__.py
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
from .window import (
|
||||
ContextDialog,
|
||||
main
|
||||
)
|
||||
|
||||
|
||||
__all__ = (
|
||||
"ContextDialog",
|
||||
"main"
|
||||
)
|
||||
26
openpype/tools/context_dialog/window.py
Normal file
26
openpype/tools/context_dialog/window.py
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
from Qt import QtWidgets, QtCore, QtGui
|
||||
|
||||
|
||||
class ContextDialog(QtWidgets.QDialog):
|
||||
"""Dialog to select a context.
|
||||
|
||||
Context has 3 parts:
|
||||
- Project
|
||||
- Aseet
|
||||
- Task
|
||||
|
||||
It is possible to predefine project and asset. In that case their widgets
|
||||
will have passed preselected values and will be disabled.
|
||||
"""
|
||||
|
||||
|
||||
def main(
|
||||
path_to_store,
|
||||
project_name=None,
|
||||
asset_name=None,
|
||||
strict=True
|
||||
):
|
||||
app = QtWidgets.QApplication([])
|
||||
window = ContextDialog()
|
||||
window.show()
|
||||
app.exec_()
|
||||
Loading…
Add table
Add a link
Reference in a new issue