-
Notifications
You must be signed in to change notification settings - Fork 196
Changes in common jqGrid dialogs
jqGrid uses by default jqModal.js
and jqDnR.js
plugins to create modal dialogs used in different parts of the code, mostly for form editing, in navigator bar and in searching dialog. jqGrid have the methods $.jgrid.createModal
, $.jgrid.viewModal
, $.jgrid.hideModal
, $.jgrid.closeModal
, $.jgrid.showModal
and $.jgrid.info_dialog
which are based on the methods from jqModal.js
and jqDnR.js
. The methods used in other parts of jqGrid to display modal dialogs.
One more common problem of the dialog methods was the behavior on closing. By default jqGrid hided all dialogs instead of destroying there. As the result the Add/Edit dialog was stay in the memory, all event handlers (for onClick events) are stay bound, the the DOM element of the grid are in use by the event handlers, the ids with the name of the columns will be used as ids of the Add/Edit form and there are stay in use (there exist) on closing of the form. All the above behavior can makes small and sometimes large problems.
The code of jqModal.js
and jqDnR.js
plugins included in jqGrid 4.7 and earlier is difficult to read and understand. The code looks like much more as minimized code as the original JavaScript code.
Free jqGrid 4.8 contains a lot of renaming and reformatting of the code of jqModal.js
and jqDnR.js
to make it more readable. Additionally is the code of jqDnR.js
changed to support drag and drop and resizing of dialogs on touch devices like iPad and the touch events of Windows 8.
Free jqGrid changed the behavior on closing of Add/Edit/Search/Delete form so that the form will be distorted by default. Only the width, height and the position of the corresponding Dialog will be saved by default. On the next opening of the same dialog the previous width, height and the position will be used. If recreateForm: true
option or recreateFilter: true
option will be used then the saved width, height and the position will be ignored.