How can I scroll dojox.mobile.EdgeToEdgeList to a particular item dojo 1.7.2? - list

I'm using a dojox.mobile.Opener to select an action from an ActionSheet.
The Action sheet should operate on an item inside an EdgeToEdgeList below that opener.
After the user selects an item, and clicks the open ActionSheet button, I would like to scroll the EdgeToEdgeList so that the selected item is at the top of the screen (not under the opener).
Does anyone have any idea how I can programmatically ask the EdgeToEdgeList to scroll up to a particular item.
Thanks,
Guy

You can use the DOM node's scrollIntoView() method.
Generic browser version:
document.getElementById('NodeIdToScrollTo').scrollIntoView();
Dojo version:
dojo.byId('NodeIdToScrollTo').scrollIntoView();
or if you would rather go via widget id:
dijit.byId('NameOfListItem').domNode.scrollIntoView();

Related

How to expose standard back button in view controller navigation?

I need users to be able to navigate a data hierarchy (master level, detail level) and to create new master and detail objects accordingly. Both master and detail use arrays for their model and TableViews for presentation
The navigation flow for this uses 2 navigation and table controllers like below. The + of the master and detail TableViews create new objects, the forstTableCell navigates to the second TableView using a segue:
While the screenshot shows "Done" right now even when removing that ButtonItem the slot remains empty.
I would like to show the standard back button instead: "< Middlewares" in this case. In the tests I've only been able to get the back button when navigating to a normal ViewController, but not to another NavigationController. Is it possible to have it between Navigation Controllers, too?
Simply remove the second navigation controller. If you use a push segue, your second view controller will still have the navigation bar. As long as you don't use a modal segue all view controllers that are pushed will have a navigation bar.
So your storyboard will look like this:
You will then automatically have a back button. If you want to change the text of it, go to your navigation item of your first view controller and change the back title accordingly as shown in this screenshot
You certainly want to have a title in your second view controller (something like "Add [whatever you want to add]". So simply drag & drop a UINavigationItem on your second view controller then you can also add UIBarButton items in your Interface builder
Controlling the look/feel of the Navigation Bar Buttons
You can achieve the behavior you want by opening the Document Outline and find the existing Done button. If you have a UIBarButtonItem type, you can simply change the type to Custom in the Inspector. Next add a regular button within the UIBarButtonItem (just bring the Navigation bar for the target controller into the zoomed in view of the storyboard/xib). This will allow you to drag a button onto the navigation bar.
Once you have a standard button you can add an image with the back arrow. Then add supporting code to use the pop behavior on the Navigation bar. Since you can have only one root navigation controller, you may want to remove the second UINavigationController and add a UINavigationItem from the objects library and then subsequently add the buttons, titles of your choice. This configuration will allow you to leverage all of the push and pop methods available, while retaining full control of the look/feel/behavior of the navigation stack.
More on customizing the look/feel/behavior of the UINavigation Stack can be found at: Navigation API Docs

O365 Custom Ribbon Action - Disable button until item selected

I'm trying to only enable my custom ribbon button when an item is selected, but it looks like you can't do JavaScript in O365 from everything that I've read. Is this true? Is there no way to enable/disable a button based on the item(s) selected?
You can use custom Page components to do that. There's an execellent article in DIWUG magazine issue 6 on how to do it. http://www.diwug.nl/DIWUG_SharePoint_eMagazine6.pdf

how to set the rights for placeholder ribbon

beginner question for sitecore about settings the right.
So I have an item is open in the page editor.
The renderings on the page has bunch of icons on the ribbon. One of them called 'select the parent element (element name)'.
In my case when I click on it, I am presented with the placeholder with button 'add here' and the ribbon with some component buttons that a user can use to add the controls.
So, QUESTION:
"how I add access to the button on that ribbon for certain role? Where do I set it up? "
For some certain role that placeholder's ribbon is completely empty, including there is no button 'select the parent element' even though
i know there is a parent element.
thank you very much for help,
HF
Here are the screenshots (no icons on the placeholder ribbon, and the user's rights:
enter image description here
And here is how that looks for the admin:
All the settings for the Page Editor are held in the Core database. So in the Sitecore Desktop, switch to the core database and open up the Content Editor.
Navigate to : /sitecore/content/Applications/WebEdit
This item holds the items that make up the page editor. To edit the ribbon menues, go to:
/sitecore/content/Applications/WebEdit/Ribbons
I don't remember seeing that particular button in the Core database, so this is likely a built-in feature that requires the user to have one of the built-in permissions.
The first thing I would check is that Designing is turned on. Have the user go to the 'View' tab in Page Editor and make sure they have checked the 'Designing' checkbox.
If that doesn't work, it sounds like the user you have does not have design access to the page. I would examine the inherited roles using the User Manager and check if they have the Sitecore Designer role inherited.
It is possible they just need to be provided the correct role in the system so that they can access the buttons.
Have you tried the "Sitecore Client developing role"?
Also, for the blue arrow drop list location, in order for the rendering button to show up in that location, you have to check whether the button in the webedit folder under core database(/sitecore/content/Applications/WebEdit/Default Rendering Buttons). The Type field needs to be "Common" in order to show up in the blue arrow droplist.
Example can be the "Edit related item" (/sitecore/content/Applications/WebEdit/Default Rendering Buttons/Edit related item) shows up in the blue arrow droplist.

how to get previously selected tab after dismissing modal IOS

I have an application using UITabBarController. There are 5 tabs (tab1, tab2, cameraTab, tab3, tab4). When user taps on middle tab , the modal view will appear hiding the TabBar (in my case camera - UIImagePickerController). If user then taps on cancel button on that modal view, how do I make it to return to previously selected tab. For example: if i am on tab2 and I tap on the camera tab, modal view appears and then I tap on cancel, how do i return back to tab2 automatically. The same goes for all other tabs, if I'm on tab3 it should return to tab 3 and so on. Right now it remains on camera tab without modal view - just blank view with background image.
I'd really appreciate if you can help me with some examples. I've been searching in various ways - there must be a way that UITabBarController keeps a record of previously selected tab.
Thank you
Personally, I think you should create a custom view where the middle camera tab would not be a tab at all, it would actually just be a button that presents the modal view and then that view would have a button to dismiss it. I would do a little research in http://idevrecipes.com/ to see if there is anything there. If not, maybe github. The tab bar itself is looking for views to push, not present.
I am sorry I couldn't give you more of an answer, but I wanted to give you something for waiting so long.

deactivate an item in the file button "jewel" in crm 2011

is it possible to hide or deactivate a menu item in the file button called also jewel button? I´m able to hide completely the file button with javascript, but I want to hide or disable only some menu items in the flyout menu.
Thank you in advance
You will find these Jewel buttons within the application ribbon. You can choose to hide these buttons in your customizations.xml via some hide HideCustomActions. The names of some of the Jewel buttons you will find are:
- Mscrm.Jewel.NewMenu.NewActivity
- Mscrm.Jewel.NewMenu.NewRecord;
For example, within your appointment ribbondiffxml section within your customizations.xml, you could have a HideCustomAction like:
<HideCustomAction HideActionId="CustomHideAction.JewelMenu.NewActivity" Location="Mscrm.Jewel.NewMenu.NewActivity" />