private RmlElementEditor openRangeEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            //Find actions
            String actionName = element.GetAttribute("onchange").StringValue;

            if (String.IsNullOrEmpty(actionName))
            {
                actionName = Guid.NewGuid().ToString();
                element.SetAttribute("onclick", actionName);
            }
            SlideAction action = slide.getAction(actionName);

            if (action == null)
            {
                action = new BlendSceneAction(actionName);
                slide.addAction(action);
            }

            //Make copy of action, this is really important, a lot of the function of this editor assumes this
            //is copied.
            SlideAction editingAction = CopySaver.Default.copy(action);

            EditInterface editInterface = setupEditInterface(editingAction, slide);

            editInterfaceEditor = new EditInterfaceEditor("Blend", editInterface, uiCallback);
            //appearanceEditor = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(editInterfaceEditor);
            return(editor);
        }
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, true);
            elementStyle.Changed += elementStyle_Changed;
            String rml = DecodeFromHtml(element.InnerRml);

            textEditor       = new ElementTextEditor(rml);
            appearanceEditor = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(textEditor);
            editor.addElementEditor(appearanceEditor);
            return(editor);
        }
예제 #3
0
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            bool hasFullscreen = element.HasAttribute("onclick");

            appearance          = new ImageElementStyle(element);
            appearance.Changed += appearance_Changed;
            appearanceEditor    = new EditInterfaceEditor("Appearance", appearance.getEditInterface(), uiCallback);
            slideImageEditor    = new SlideImageComponent(editorResourceProvider, subdirectory, element.GetAttributeString("src"), hasFullscreen);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(slideImageEditor);
            editor.addElementEditor(appearanceEditor);
            return(editor);
        }
예제 #4
0
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, true);
            elementStyle.Changed += elementStyle_Changed;
            appearanceEditor      = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);

            dataElementEditor = new DataElementEditor(element);
            EditInterface editInterface = dataElementEditor.EditInterface;

            editInterfaceEditor = new EditInterfaceEditor("Data Display Properties", editInterface, uiCallback);
            dataElementEditor.EditInterfaceEditor = editInterfaceEditor;
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(editInterfaceEditor);
            editor.addElementEditor(appearanceEditor);

            return(editor);
        }
예제 #5
0
        public override RmlElementEditor openEditor(Element element, GuiFrameworkUICallback uiCallback, int left, int top)
        {
            elementStyle          = new TextElementStyle(element, false);
            elementStyle.Changed += elementStyle_Changed;
            String rml = TextElementStrategy.DecodeFromHtml(element.InnerRml);

            textEditor = new ElementTextEditor(rml);
            String actionName = element.GetAttribute("onclick").StringValue;

            if (String.IsNullOrEmpty(actionName))
            {
                actionName = Guid.NewGuid().ToString();
                element.SetAttribute("onclick", actionName);
            }
            SlideAction action = slide.getAction(actionName);

            if (action == null)
            {
                action = ((Func <String, SlideAction>)actionTypeBrowser.DefaultSelection.Value)(actionName);
                slide.addAction(action);
            }

            //Make copy of action, this is really important, a lot of the function of this editor assumes this
            //is copied.
            SlideAction editingAction = CopySaver.Default.copy(action);

            EditInterface editInterface = setupEditInterface(editingAction, slide);

            actionEditor     = new EditInterfaceEditor("Action", editInterface, uiCallback);
            appearanceEditor = new EditInterfaceEditor("Appearance", elementStyle.getEditInterface(), uiCallback);
            RmlElementEditor editor = RmlElementEditor.openEditor(element, left, top, this);

            editor.addElementEditor(textEditor);
            editor.addElementEditor(actionEditor);
            editor.addElementEditor(appearanceEditor);
            return(editor);
        }