moved path an text entity to inputs

This commit is contained in:
iLLiCiTiT 2021-01-22 14:13:22 +01:00
parent 354d28236c
commit 7517fa5ba7
2 changed files with 21 additions and 21 deletions

View file

@ -239,6 +239,27 @@ class EnumEntity(InputEntity):
self._current_value = value
class TextEntity(InputEntity):
schema_types = ["text"]
def item_initalization(self):
self.valid_value_types = (str, )
self.default_value = ""
class PathInput(TextEntity):
schema_types = ["path-input"]
def item_initalization(self):
self.with_arguments = self.schema_data.get("with_arguments", False)
if self.with_arguments:
self.valid_value_types = (list, )
self.default_value = []
else:
self.valid_value_types = (str, )
self.default_value = ""
class RawJsonEntity(InputEntity):
schema_types = ["raw-json"]

View file

@ -856,27 +856,6 @@ class GUIEntity(ItemEntity):
self.require_key = False
class TextEntity(InputEntity):
schema_types = ["text"]
def item_initalization(self):
self.valid_value_types = (str, )
self.default_value = ""
class PathInput(TextEntity):
schema_types = ["path-input"]
def item_initalization(self):
self.with_arguments = self.schema_data.get("with_arguments", False)
if self.with_arguments:
self.valid_value_types = (list, )
self.default_value = []
else:
self.valid_value_types = (str, )
self.default_value = ""
class PathEntity(ItemEntity):
schema_types = ["path-widget"]
platforms = ("windows", "darwin", "linux")