forked from LeenkxTeam/LNXSDK
Webview for RunT/Krom
This commit is contained in:
24
leenkx/blender/lnx/logicnode/krom/LN_webview_page_info.py
Normal file
24
leenkx/blender/lnx/logicnode/krom/LN_webview_page_info.py
Normal file
@ -0,0 +1,24 @@
|
||||
from lnx.logicnode.lnx_nodes import *
|
||||
|
||||
|
||||
class WebviewPageInfoNode(LnxLogicTreeNode):
|
||||
"""Gets the current URL or page title of the given WebView"""
|
||||
bl_idname = 'LNWebviewPageInfoNode'
|
||||
bl_label = 'Webview Page Info'
|
||||
lnx_category = 'Krom Runtime'
|
||||
lnx_section = 'webview'
|
||||
lnx_version = 1
|
||||
|
||||
property0: HaxeEnumProperty(
|
||||
'property0',
|
||||
items=[('url', 'URL', 'Get the current URL'),
|
||||
('title', 'Title', 'Get the page title')],
|
||||
name='Info', default='url')
|
||||
|
||||
def lnx_init(self, context):
|
||||
self.add_input('LnxIntSocket', 'ID')
|
||||
|
||||
self.add_output('LnxStringSocket', 'Value')
|
||||
|
||||
def draw_buttons(self, context, layout):
|
||||
layout.prop(self, 'property0')
|
||||
Reference in New Issue
Block a user