In Pages, Numbers, and Keynote 3.3 for iOS, Apple has done away with its custom file manager and instead uses the a version of the iOS 11 Files App to allow the user to choose and save files within the applications,
The Files-like document picker User Interface on Pages and Keynote 3.3 for iOS 11:
Is this a publicly available view controller that developers can implement in 3rd-Party Applications?
Apple mentions in a user support document that these apps "work together" to present this view. Link: https://support.apple.com/en-us/HT208077
It is UIDocumentBrowserViewController.
As far as "how did they make it the root view controller of the app? Isn't [it] usually presented from another View Controller?"
Check this page: Adding a Document Browser to Your App.
Always assign the document browser as your app's root view controller.
Don't place the document browser in a navigation controller, tab bar,
or split view, and don't present the document browser modally.
There are a lot of useful resources on that page, but a lot seems to hinge on your app being "Document Based" (About Document-Based Applications in iOS).
Related
Until XCode 6.2 beta 3 I was able to navigate in the hierarchy and push new interfaces from a button on any of my two pages relationated interfaces controllers.
Such as this:
This used to make such a weird result as stated here
But now, this appears to be a no go. Xcode doesn't state anything on this matter to alert, it just do nothing when you tap on the button that push the new interface.
I can only change that push for a modal to get it work.
But that is limiting my navigation stack as modal are final nodes of the navigation tree.
Also, this is a no go too:
XCode is forcing me to obtain this result only if that push is changed for a modal!!!!
Any workaround please!
This is tying my hands at my back.
You can't do what you are describing, and it is by design. If you were able to do it in a previous Xcode beta, Apple presumably saw that as a bug. They have been quite explicit that you can choose either page-based or hierarchical-interfaces, and that these are mutually exclusive. Both have the ability to present a modal view at any time.
From the Apple Watch Programming Guide:
Interface Navigation
For WatchKit apps with more than one screen of content, you must choose a technique for navigating between those screens. WatchKit apps support two navigation styles, which are mutually exclusive:
Page-based. This style is suited for apps with simple data models where the data on each page is not closely related to the data on any other page. A page-based interface contains two or more independent interface controllers, only one of which is displayed at any given time. At runtime, the user navigates between interface controllers by swiping left or right on the screen. A dot indicator control at the bottom of the screen indicates the user’s current position among the pages.
Hierarchical. This style is suited for apps with more complex data models or apps whose data is more hierarchical. A hierarchical interface always starts with a single root interface controller. In that interface controller, you provide controls that, when tapped, push new interface controllers onto the screen.
Apps can use modal presentations to supplement their base navigation style. Modal presentations are a way to interrupt the current user workflow to request input or display information. You can present interface controllers modally from both page-based and hierarchical apps. The modal presentation itself can consist of a single screen or multiple screens arranged in a page-based layout.
In my app I have dropbox implementation and user can download the documents from dropbox and see that one by one like a slideshow. My Problem is that if user downloads .ppt file then how to show powerpoint presentation with all its animations on iPhone without using other app like slide shark.
Only way is Using the Quick Look Framework.
Use the Quick Look framework to provide previews of items that are in formats you don’t handle—such as iWork or Microsoft Office. This framework affords you more control over the preview process than you get from the UIDocumentInteractionController class—including choosing whether the preview is displayed in the context of a navigation controller or modally (full screen). The primary class in this framework is QLPreviewController, which provides a specialized view for previewing an item. It relies on a delegate for mediating preview actions, and a data source for providing the preview items.
In iOS 4.2 and later, the specialized view presented by a Quick Look preview controller includes an action button with a Print item. If the controller can provide a preview of a file, it can also print it. There is no printing code for you to write.
To display a Quick Look preview controller you can use any of these options:
Push it into view using a UINavigationController object.
Present it modally, full screen, using the
presentModalViewController:animated: method of its parent class,
UIViewController.
Present a document interaction controller (as described in
“Previewing and Opening Files.” The user can then invoke a Quick
Look preview controller by choosing Quick Look from the document
interaction controller’s options menu.
A Quick Look preview controller can display previews for the following items:
Microsoft Office documents (Office ‘97 and newer)
iWork documents
Rich Text Format (RTF) documents
PDF files
Images
Text files whose uniform type identifier (UTI) conforms to the
public.text type (see Uniform Type Identifiers Reference)
Comma-separated value (csv) files
look at UIDocumentationInteractionController, which may be easier than using Quick Look, depending on your needs, you can control animation better then Quick look but need lots of digging.
I just read some articles on UIActivityViewController and UIDocumentInteractionController in iOS, but I am very confused about how to use them because both seem the same.
So, when do I use UIActivityViewController or UIDocumentInteractionController?
Is there any difference for Open In... & use UIActivityViewController?
I am very confused about how to use them. Please clarify to me their specific use.
In short, UIDocumentInteractionController deals with files while UIActivityViewController deals with various other services in your app. I'm not one to criticize much but you really should at least try to google and read at least the overview in the iOS Developer Docs.
UIDocumentInteractionController documentation:
A view controller that previews, opens, or prints files whose file format cannot be handled directly by your app.
...
Use this class to present an appropriate user interface for previewing, opening, copying, or printing a specified file. For example, an email program might use this class to allow the user to preview attachments and open them in other apps.
After presenting its user interface, a document interaction controller handles all interactions needed to support file preview and menu display.
You can also use the delegate to participate in interactions occurring within the presented interface. For example, the delegate is notified when a file is about to be handed off to another application for opening. For a complete description of the methods you can implement in your delegate, see UIDocumentInteractionControllerDelegate.
UIActivityViewController documentation:
A view controller that you use to offer standard services from your app.
...
The system provides several standard services, such as copying items to the pasteboard, posting content to social media sites, sending items via email or SMS, and more. Apps can also define custom services.
Your app is responsible for configuring, presenting, and dismissing this view controller. Configuration for the view controller involves specifying the data objects on which the view controller should act. (You can also specify the list of custom services your app supports.) When presenting the view controller, you must do so using the appropriate means for the current device. On iPad, you must present the view controller in a popover. On iPhone and iPod touch, you must present it modally.
Basically UIActivityViewController shares Data Objects (like Strings or Images) where UIDocumentInteractionController shares whole Documents / Files f.e. a PDF.
I am finishing an iPhone app for my company.
I am using Xcode and Xpages, as we are a Lotus Notes shop.
In Xcode I am using a UINavigation Controller with a Table View for selections. One selection is the Company Directory, which is an Xpage using the Xpages Mobile Controls (Single Page Application and then Application pages, etc.). This works fine EXCEPT for the navigation hand off between the Xcode parts of the app and Xpages. I end up with two sets of navigation controls, which is not good.
Any ideas how I can get around this?
Bryan
OK, I think I figured this out.
It really isn't anything to do with Xpages, but with using UIWebViews within iOS.
The problem was that on the first webView, I wanted to show the iOS Navigation, but in any subsequent ones I didn't want to - would just prefer to use the web navigation.
There is a delegation method in iOS Web views that allows you to show or hide the navigation bar. I added this delegate and just check to see which page I am on. If on the first one, I show the iOS Navigation, else I suppress.
This works great!
We have a client who wants to build an app that essentially functions as a media kit that they distribute to clients. In addition to several videos, they would like to embed their Keynote presentation inside of the app. The presentation would also contain some videos on certain slides. Is there some sort of viewer that would allow me to embed the presentation inside the app? At the very least, is it possible to launch Keynote from inside the app to the specified presentation, and then return control to my app immediately upon closing Keynote?
Thanks,
Mike
UIWebView can display iWork files. I don't think it will play videos on slides, though.
Edit: You can use UIDocumentInteractionController to have the user preview the file and then launch Keynote if they want to. But AFAIK there is no way to do this programmatically without user intervention. Even if Keynote supports a URL scheme, there would be no way to pass the file.
If you post the presentation to iWork.com you can use a web view to play it back via the site's show-embedding mechanism.