[jbosstools-issues] [JBoss JIRA] (JBIDE-16321) Smart DnD from jQuery Mobile Palette

Viacheslav Kabanovich (JIRA) issues at jboss.org
Fri May 16 15:15:59 EDT 2014


    [ https://issues.jboss.org/browse/JBIDE-16321?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12968529#comment-12968529 ] 

Viacheslav Kabanovich commented on JBIDE-16321:
-----------------------------------------------

We can insert jQuery widget to the nearest appropriate place to cursor position. In dnd, that place will be shown, as it is already done in JBIDE-16345 to insert widgets outside of area between < and >.

In general, either if we cannot find an appropriate place, or if the current position may be appropriate, the widget should be dropped at the current position.

1. Page, Dialog. 
Pages should be direct children of <body>. New page should be inserted to the nearest place that has <body> for parent (if <body> is missing then under <html> after <head>).

2. Header, Footer, Panel. 
Page has structure:
<div data-role="page">
<!--panels-->
<!-- header-->
<!--content-->
<!--footer-->
<!--panels-->
</div>
a) header/footer should be inserted to the nearest/current page that still does not have that section, according to the required structure;
b) panel should be inserted into the nearest/current page, into the nearest appropriate place according to the required structure.
If there is no appropriate place for header/footer/panel, show a warning in wizard, but allow to finish at the selected place. 

3. All other widgets should be inside panel, header, content, footer.
a) if cursor is outside pages, the widget should be inserted to the content of the nearest page;
b) if cursor is in a page but outside sections, the widget should be inserted to the nearest section, as either its first or its last child, what is the nearest;
c) if cursor is inside a section, insert the widget to the selected position (just out of <>).
If there is no available section for the widget, show a warning in wizard, but allow to finish at the selected place. 


> Smart DnD from jQuery Mobile Palette
> ------------------------------------
>
>                 Key: JBIDE-16321
>                 URL: https://issues.jboss.org/browse/JBIDE-16321
>             Project: Tools (JBoss Tools)
>          Issue Type: Feature Request
>          Components: jsp/jsf/xml/html source editing
>            Reporter: Alexey Kazakov
>            Assignee: Daniel Azarov
>              Labels: new_and_noteworthy
>             Fix For: 4.2.0.Beta2
>
>
> When adding a widget via the jQuery Mobile Palette, we should inject the HTML in a proper place of the page, not just wherever the cursor happens to be. For example a page may be injected only between pages.



--
This message was sent by Atlassian JIRA
(v6.2.3#6260)


More information about the jbosstools-issues mailing list