Opened 13 years ago

Closed 9 years ago

#572 closed defect (inactive)

new popup-dialogs-system

Reported by: niko Owned by: niko
Priority: normal Milestone: 2.0
Component: Xinha Core Version:
Severity: normal Keywords: dialog popup branch new-dialogs
Cc:

Description

Currently the Linker-plugin and the SuperClean?-plugin use the inline-dialog.js

  • all dialogs should be changed to use this dialog-system
  • there should be alternatives to inline-dialog which can be activated thrugh the config
    • an inline-dialog that displays the dialog IN xinha directly (as Linker + SuperClean? currently do)
    • a floating-dialog much like inline-dialog but can be dragged around in the document - can can be bigger than xinha (which was in some cases a problem of inline-dialog)
    • a popup-dialog that just opens a new window (like all other current dialogs)

I have created a branch for this: source:branches/new-dialogs

Change History (5)

comment:1 Changed 13 years ago by niko

commited the first version in changeset:404

To test it open full-example.html and select the dialog-type in the menu.

Working:

  • the standard xinha-dialogs for insert image, create link and create table
  • all three dialog-types for these
  • the SuperClean? dialog

Not yet finished:

  • the Linker dialog
  • test the whole thing in IE
  • styling of the dialogs
  • window-size of popup and floating-dialogs
  • all other dialogs of other plugins

Anybody that wants to help is free to do so :D

gogo and others - please review my code and tell me what i can do better or easier :D (i actually don't have much practise in JavaScript?)

comment:2 Changed 13 years ago by gogo

Havn't looked at the code, but a couple of things...

  1. Image picker doesn't fit in the inline dialog, it's kinda wierd (probably there is some absolute positioning?) or floating.
  1. Moving the floating dialog is very slow because it's redrawing continuously as you move it. Also means you can get the mouse outside of the "titlebar" while still leaving the "dragging turned on", so when you move the mouse backin the title bar (with mouse button released already) it still drags. Would be better to perhaps just move an outline of the window.

comment:3 Changed 13 years ago by gogo

Your code looks fine, a couple of suggestions

  1. The default behaviour should be normal popup windows I think, at least for now.
  2. There are a number of functions which are common between the three, for example HTMLArea.Dialog.prototype.loadScript, these should be placed into one single file (dialog.js) which is loaded, rather than have a copy in each of the individual xxxx-dialog.js

comment:4 Changed 13 years ago by niko

thanks for your review!

1.1 Moving the floating dialog is very slow
I noticed this is only slow on linux (at my windows-machine it is faster)

1.2 Would be better to perhaps just move an outline of the window.
that is a great idea!

2.1 The default behaviour should be normal popup windows I think, at least for now.
that part is still the buggiest, so i set the well-tested inline-dialog as default. but can be changed easily...

2.2 HTMLArea.Dialog.prototype.loadScript, these should be placed into one single
file (dialog.js)
that is true, i will look into this...

comment:5 Changed 9 years ago by gogo

  • Resolution set to inactive
  • Status changed from new to closed

Old, inactive, and we have new dialogs in the trunk for ages now.

Note: See TracTickets for help on using tickets.