Extjs 6 Ext.grid.plugin.RowEditing Remove Update / Cancel buttons - extjs6

I am trying to remove update cancel buttons.
but no any config's are available for this.
I have tried to override but i cant remove this.
please if you have done task like this or know how to do this help me.

You're absolutely right that there is no built-in way to hide the update and cancel buttons with the row editing plugin.
You could try to hide the button bar via CSS. The normal CSS class name is x-grid-row-editor-buttons. But this may cause other problems.
Or, you could try a different editor, such as the CellEditing plugin - this lets you edit one cell at a time, as opposed to showing the editors for the entire row, and doesn't use buttons.

You might be able to remove the button by overriding the Ext.grid.plugin.RowEditing. A quick look at the source shows me an array with in the initEditiorFunction() which looks like this.
btns = ['saveBtnText', 'cancelBtnText', 'errorsText', 'dirtyText'],
Try removing the cancelBtnText button, and perhaps it won't show on there? I haven't tested this but this might be something in the right direction.

Related

Is there a specific component that works with Swift 3 to represent a "ComboBox / Spinner"?

I'm starting to work with Swift 3 and I'm having difficult to find a "easy" solution to create a "ComboBox/Spinner".
I saw some alternatives like using PickerView and Collapse TableView, but It seems to be a solutions to make these components to looks like a ComboBox, It's a adaptation, but It's not a "real comboBox".
I would like to know If there's a component that works with Swift 3 that really represents a ComboBox/Spinner.
Thank you.
As Eric says in his comment, controls aren't defined in Swift, they're defined in the OS frameworks.
iOS does not have a combo box. That's a Windows thing. The standard system component for picking items from a list is a UIPickerView. I've implemented a custom control that's rather like a combox box before, and you may be able to find a 3rd party control that does what you want.
Don't know if this is the kind of combobox system you are looking for:
https://gyazo.com/ce6388cf29f9c33f67df2b6a54c95768
If so you could create a custom button which looks like a combobox. Then if not selected you have an image of a not selected combobox and when someone selects the button change it to the image of a selected combobox.
You create an array, add the amount of custom buttons to the array as you want, you give each button the same selector. Then when someone selects an item, deselect another button if there is one selected and select the button the user did press.
I hope this helps you.

How to create stacked pagination in iOS?

How to achieve the UI as shown in the image below?
I wanted to create a form with steps, by clicking next button it will swipe and open next form and will update the number of stacked pages as shown.
For making this type of UI you need to use Background image and UIPageControl. And you have to make other UI elements like text fields and button with code. You should be careful about frames.
Finally I got the answer, and created the same UI using Koloda library in objective-c
https://github.com/wang9262/Koloda-ObjC

nsISelectionDisplay custom highlight controller? (related to nsISelectionController)

I made an addon HiliteOnSelection, when hilight something it uses the SELECTION_FIND context to highlight other instances. The issue with this is that highlight all feature of find bar uses same controller.
http://mxr.mozilla.org/mozilla-release/source/content/base/public/nsISelectionController.idl#30
Can you please help me to figure out how to create my custom highlight controller and how to style it, the SELECTION_FIND is pink.
This is how i get the selection_find context/controller and highlight with it:
https://addons.mozilla.org/en-US/firefox/files/browse/247620/file/bootstrap.js#L147
let findSelection = controller.getSelection(Ci.nsISelectionController.SELECTION_FIND);
findSelection.addRange(aRange);
I got this reply from the addon author. He's a nice guy:
Hey Noitidart,
You might find this one helpful:
https://developer.mozilla.org/en-US/docs/XPCOM_Interface_Reference/nsISelectionController
I'm hardly the master you think I am, actually. :) To change those
colors I just change the values for preferences:
ui.textHighlightBackground ui.textHighlightForeground
ui.textSelectBackgroundAttention -> SELECTION_ATTENTION, it's not a
highlight, it's a normal selection (as you would select some text with
your mouse and it would turn the regular blue blackground, in windows
at least) but it's given "attention", so it has the green background
that the find operation reports. Basically it's a way of showing the
user "Here I am!!" after firefox automatically selecs the text he
searched for.
And I really don't know most of those contants, SELECTION_NORMAL is
for normal text selection, like it would be when you select text with
your mouse, SELECTION_FIND is for the highlights, and I only know the
ON/HIDDEN/OFF/DISABLED ones which are self-explanatory.
SELECTION_SPELLCHECK is probably for the auto-correct when you are
typing in an editable content node, but I'm just guessing that one
from the name.
Also, as far as I know, it's not possible to just create custom
selection ranges/contants, as the code simply won't recognize them
without editing the C++ code as well. Which is actually one of the
reasons I haven't implemented
https://github.com/Quicksaver/FindBar-Tweak/issues/76 yet.
Hope any of this helps. I'm sorry to disappoint on the custom
controller thing.
Luís Miguel
So he changes the colors with a simple pref change. I'm going to have to dig into how that pref changes it.
He also thinks its not possible to create custom controllers without C++, I hope this is not true I'll keep digging if anyone can help that would be great.

Extjs with Rails- Problem in adding button dynamically on Panel

I am using ExtJS 3.2.1 with Rails 3.x.
I have a Panel on which I want to add ExtJS Buttons "dynamically" depending upon the number of records in the db. I tried googling but no luck.
Any Suggestions?
Thanks in advance !
It not clear in your question where you are adding the button. Are you adding it into a toolbar or into buttons section of a panel. Either way, you should be able to use the addButton method available for Toolbar and Panel.
panel.addButton({your button config});
Now, to create buttons you will have to wrap it in a loop. Before that you will have to get the necessary data from DB. For getting data, you can use the Ext.Ajax class and according to the response, iterate and create the buttons.

jQuery UI Accordion (or similar) with multiple header lines

I'm trying to show a list of messages to the user where the first two lines from each message are showing and they can click to see more.
So I was thinking the accordion would be an interesting way to do this. The only problem is that I can only show the normal single line header row. Is there a way I can show multiple lines or do I need to look for an alternative control like Kwicks?
Ive just given it a go and you can use a < br > inside of the h3 to give it an extra line, or maybe try setting the wraping attributes for the css if you cant manually put a line break in.
Take a look at http://jsfiddle.net/YY7ML/ for a basic example.
Or maybe I have misunderstood?

Resources