Jump to content

estrify

uniGUI Subscriber
  • Posts

    454
  • Joined

  • Last visited

  • Days Won

    14

Everything posted by estrify

  1. Thanks for the answer... The plugin is very useful but I need to adjust paging automatically to the available space exactly ... This is why I need the height of different components to calculate the number of lines to be displayed avoiding to show grid's vertical scroll bar... I have already achieved it... Thanks a lot.. Regards,
  2. Thanks for response. But by now, this is insufficient... However, I have found a way to workaround this... Please, consider add the dynamic changing of the PageSize as a new feature... By now, here is how to achieve it: dbgrd.WebOptions.PageSize:=iNewPageSize; /* for now this has no effect. Only to be "clean" */ UniSession.AddJS( dbgrd.JSName+'.getStore().pageSize='+IntToStr(iNewPageSize)+';'+ dbgrd.JSName+'.getStore().load({params: { limit: '+IntToStr(iNewPageSize)+' }});'+ dbgrd.JSName+'.getView().refresh();' ); One more question: in UniDBGrid, is there a way to retrieve the total height of headers (considering grouping and so on) and the pager?? Regards,
  3. Hi, I have a paged dbgrid that has akRight and akBottom anchors. At runtime, when I change PageSize of the grid to adapt its content to the available space after a form resizing, the paging bar does not update its initial parameters. How can I update them?. Sure I am missing something trivial but if not, is there a workaround to achieve this result?? Thanks in advance...
  4. estrify

    Drag Form

    Hi, The following might help you: add into Your form -> ClientEvents -> UniEvents -> Ext.window.Window -> window.beforeInit the following line: sender.constrainHeader = true; Regards,
  5. Please take a look to http://forums.unigui.com/index.php?/topic/6119-simple-tip-combobox-wider-drop-down-picker/... Is not exactly what you are asking for but it may help you to make some combos more legible... Regards
  6. Are Main form and LoginForm derived from TUniLoginForm?... Make sure that only one form is derived from TUniLoginForm and all your forms (login one also) are correctly registered (initialization section with its RegisterAppFormClass)...
  7. Hi, I think that when you derive (and register) a form from TUniLoginForm, this form will be automatically created and shown by framework for each new session, unless you especify "Handled:=true" in the OnBeforeLogin procedure of UniMainModule... Regards,
  8. Hi, This was redisigned... Please, look at "Session List" demo to see how it must be managed now... Regards,
  9. estrify

    messagedlg

    Hi,I think this is related to a simple namespace problem. This messagedlg you indicate is executing a Dialogs.MessageDlg function, not unigui's one... Look at example suggested by Delphi Developer... Regards,
  10. Hi Delphi Developer, Thanks for this plugin, is very, very useful ... Sorry for the daring but how can you associate with a UniTabSheet a UniPageControl instead of a button ??... and with a UniMenuItem??? Thank you in advance...
  11. Hi, For some combobox I am using, I need to make the picker wider than the combo itself (see image). If you need something similar, add the following code to your combo: Within "Combobox -> UniEvents -> Ext.form.field.Combobox -> afterCreate", add the following function afterCreate(sender) { Ext.apply(sender, { matchFieldWidth: false, pickerOffset: [0,-1] }); var picker; picker=sender.getPicker(); picker.maxWidth=sender.width*2; // Here, change the multiplier to adjust it to your needs, // or directly specify a width picker.border=1; } Best regards,
  12. Meanwhile, take a look to http://forums.unigui.com/index.php?/topic/5792-simple-tip-checkcombobox-plugin/ Regards,
  13. Hi, I show a simple use of a CheckComboBox Plugin... Add "CheckComboBox_Plugin.js" to UniServerModule->CustomFiles (adjust the path to the .JS file to yours) Add the following to UniServerModule->CustomCSS (adjust the path to the .GIF file to yours): .ux-boundlist-item-checkbox { background-repeat: no-repeat; background-color: transparent; width: 13px; height: 13px; display: inline-block; line-height: 13px; background-image: url('checkbox.gif'); background-position: 0 0; } .x-boundlist-selected .ux-boundlist-item-checkbox { background-position: 0 -13px; } Add UniComboBox->ExtEvents->Ext.form.field.ComboBox -> change function change(sender, newValue, oldValue, eOpts) { for (var i=0; i<newValue.length; i++) { var found=false; for (var j=0; j<oldValue.length; j++) if (newValue[i]==oldValue[j]) { found=true; break;} if (!found) ajaxRequest(sender, "checkevent", [ "text="+newValue[i] ]); } for (var i=0; i<oldValue.length; i++) { var found=false; for (var j=0; j<newValue.length; j++) if (oldValue[i]==newValue[j]) { found=true; break;} if (!found) ajaxRequest(sender, "uncheckevent", [ "text="+oldValue[i] ]); } } Add to UniComboBox->UniEvents -> Ext.form.Field.ComboBox -> beforeInit: function beforeInit(sender, config) { Ext.apply(sender, { emptyText: 'empty text', multiSelect: true, plugins: Ext.create('Ext.ux.form.plugin.CheckComboBox') }); } Look at Main.pas to see sample ways to do things... I hope you find it useful to adapt it to your needs... Regards, 20150928_CheckComboBox_Plugin.rar
  14. Hi, Is there a way to extend OnRemoteQuery?... I need to calculate a new string proporty each time RemoteQuery is called (a kind of persistant query string) but I don't find the way. Is there another way to do that? TIA
  15. Sorry... It's my fault... Restarting IDE compiles correctly...
  16. Hi, Please, might you tell me hoy to override "OnAjax" event in a TUniComboBox?? ... (I have overrided it successfully in a TUniEdit but don't know how to proceed within a TUniComboBox) TIA
  17. Only one note: if you use Sysutils.Format, you need to use the version with FormatSettings
  18. Found: procedure DoHandleEvent(AEventName: String; AParams: TUniStrings); override;
  19. Hi, Please, it is possible to override OnAjaxEvent when extending components??... TIA
  20. Sorry... It's my fault... Simply have to use: JSProperty('plugins', 'Ext.create("Ext.ux.form.field.ClearButton", {serverSideClear: false})');
  21. Hi, I am making some tests with custom components. How can I use a plugin with them??... i.e. I want to extend TUniEdit to use ClearButton plugin... Using a normal TUniEdit and ClientEvents it is easy, but I don't know how to make it work directly in a custom component... in WebCreate the following produce ajax error: JSConfig('plugins', ['Ext.create("Ext.ux.form.field.ClearButton", {serverSideClear: false})']); TIA
  22. Works ok... License received... THX...
  23. Hi, Keep in mind that UniGUI could easily collapse server's CPU time (several seconds with CPU over 80%). In our case, trying to preload 8 dynamically generated frames with 68 component on each, half of them, labels (544 components in total) causes more than 35 seconds delay, with the usage of server's CPU above than 75% (with several seconds at 100%)... Regards, Hola, Ten en cuenta que UniGUI podría colapsar fácilmente la CPU del servidor (varios segundos con la CPU a más del 80%). En nuestro caso, una precarga de 8 frames generados dinámicamente con 68 componente en cada uno, la mitad de ellos etiquetas (544 componentes en total) necesita más de 35 segundos, con el uso de la CPU del servidor por encima del 75% (con varios segundos al 100%) ... Saludos,
×
×
  • Create New...