Prevent Notification thumbnail from showing when 3D-touching - ios

I am creating notifications in an app with iOS >10. When I attach an image to this notification, it shows exactly as I want it, but when the user 3D-touch the notification, the image is shown almost full screen.
The image has almost nothing to do with my notification; it only works as an indicator, and I would like for it to keep the tiny 70px thumbnail-size when a user force-touches it, or remove it all together in this expanded state. Is this possible?
This is exactly as I want it ^
I do not want the image to grow so much!
Is there a way to prevent the thumbnail from being this huge? The image's size is 70x70..

I ended up using a NotificationContentExtension to solve this. This extension adds a new target to your project, with its own storyboard and .plist and everything. It was really overkill for my project, as it was a lot of work, but I wanted to get rid of that blown-up thumbnail.
This extension can communicate with your app, so we were able to put a lot of nice information into the extended notification, and it actually turned out looking great. You design everything yourself, like what happens when you 3D-touch a notification from the Calendar app. You could probably also use an empty xib/storyboard for this extension to simply remove the thumbnail, but I just went nuts and created gold. It is practically a UIViewController that you can design to show whatever you want.
I did read quite a few tutorials on the matter. This is one of them.

Related

What is this popup object called in iOS?

What is the pop-up object used in the Apple's "Clock" app for iPad called?
The popup looks similar to a MapKit callout, but often comes out of the side of a clicked button. Apple uses the pop-up often to display pickerViews on iPad. I am wanting to use it also for iPad applications in Swift, but I cannot find the name anywhere in documentation or on StackOverflow--because I don't know what it is called and it is thus hard to find.
I already know that some may not like the simplicity of this question, but I have seriously tried and have looked through books and other documentation trying to identify what the name of it, but it is so hard to find it without knowing the name! (I've included an image of the object just to be clear, but, unfortunately, I don't have the 'reputation' for the image to show up automatically in StackOverflow)
Image: The Object/PopUp item used in the "Clock" App.
The object is a Popover, as identified by Dan.
Thank you those who contributed.
You must be talking about UIDatePicker.

How to make my LaunchImage load at the same time as the application?

As the application loads, I want to make an image load at the same time, for example, a line would elongate form either side as the application loads, and when it has finished, the line would have reached its maximum length. I have seen this in a few websites, like rime arodaky for example, but I want to this for an iOS application. I have searched on Google but couldn't find anything!
Does anyone know how to do this?
The launch process if we REALY simplify it to accommodate your question, can be split into two parts.
The first part you do not have any control over, and during which a launch image is shown.and it ends with a delegate call-back on the application delegate called
applicationDidFinishLaunchingWithOptions
The second part is you might have some application specific behaviour which requires no activity from the user but you app still isn't interactive.
You need to implement such a progress bar yourself. There is no built in support for this in any of the app templates in Xcode.
You can only do what you want during this second phase. But you have absolutely no control over the first phase, except for that static non-animated launch image.
I think you can just add a photo as a launch image, launch image is just an image.Then you can add the animation when your first view controller appears.You can fake it this way.

How to make a slider volume controller on iOS? Objective-C, iOS 7 (or 8), xcode 5 (or 6)

I am learning to develop iphone apps and I have a simple question.
I am making a really simple app which allows the user to set the volume of the device on the settings screen using a slider instead of the volume buttons.
It may be quite obvious for experienced developers but I just can't find the answer I am looking for.
My question is:
How can I make this slider?
Basically I want to do this (image: https://www.dropbox.com/s/b81bzdwyrab0ha7/slider.png?dl=0):
I used to think that I could use a regular UISlider but some documentation says that I need to use something called a MPVolumeView. The problem is that I can´t find a good tutorial that tells how to use this explicity.
I found this link on the apple documentation but I dont understand how this works. – http://developer.apple.com/iphone/library/documentation/MediaPlayer/Reference/MPVolumeView_Class/Reference/Reference.html
And the description says: Use a volume view to present the user with a slider control for setting the system audio output volume, and a button for choosing the audio output route. When first displayed, the slider’s position reflects the current system audio output volume. As the user drags the slider, the changes update the volume. If the user presses the device volume buttons while sound is playing, the slider moves to reflect the new volume.
This is exactly what I want but I dont understand the example it gives. If you could please tell me how t make this slider work, even if it is on a new one-view project, I would really appreciate it.
Also I am aware that this method also creates an airPlay button next to the volume slider. Is there a way to delete this button? (My app is a simple productivity app so I only want the slider, not the airplay button).
I also understand that this will not work on the simulator. How am I supposed to know that this will work without having to test it on an actual device (I am not registered as a developer yet)?
Plus, I only know objective-c, not swift. If you could please restrain from using swift in your answers I would apreaciate.
Thank you so much for your help.
PD: English is not my first language. Sorry for any mistakes I made.
The MPVolumeView class is designed to let you do exactly this. It's in MediaPlayer.framework, so add that to your app to make things build correctly.
You create it and make it visible the way you instantiate any other subclass of UIView, which you probably know by now.
You disable the routing button by setting the "showsRoutingButton" property to false.
"How am I supposed to know that this will work without having to test it on an actual device?"
By seeing that it's been there since iOS 2.0, and is used in countless apps?
The process to writing such a slider is incredibly simple, look into UISlider(https://developer.apple.com/library/ios/documentation/UIKit/Reference/UISlider_Class/) and then use the float value from the slider to set the volume.
If you do not want to write your own slider, look on GitHub(github.com) for controls that do this for you. After doing a quick search, I found this UISlidersubclass that adjusts volume.

Ios default icon for open view from list

In every ios app you can have a list that contains elements with subelements.
Tapping on the element will open a new page and you can usually press back to return.
This is indicated with a grey ">" symbol on the right.
Is this symbol downloadable somewhere? I know i can just type a > but it doesn't look exactly like the default icon used by ios.
I'm using Xamarin dialog and a standard RootElement embedded as a list item looks exactly like the default ios but i need to customize it with an icon placed left of the text(which is no problem except that i now lose the default > icon).
Googling for ios system icons, ios default icons and ios sdk did not yield the wanted result. I'm hoping that these icons are somewhere embedded on the device.
I hope you guys can help me out, thanks !
As far as I know there is no way to access a UIImage instance of the chevron during run time. Most likely there is private API for this, but I am not aware of it, and since it's private you are not allowed to use it anyway.
You could probably instantiate a cell that has the disclosure indicator as accessoryType and walk the view hierarchy to find it. But that will break easily, so don't do it.
The best way is to add an image and update it with every new iOS release.
There's the iOS Artwork Extractor which basically gets you every piece of artwork that is used in iOS.
The artwork you are looking for should be named UITableNext. (at least that's the name in iOS6, I don't have an extracted archive of iOS7 yet)
Strictly speaking you are violating Apples rules and their copyright if you use their artwork without Apples written consent.
As far as I know this has never been enforced, and lots of people do it, but it's good to keep it in mind.

Custom Image iPhone Keyboard

Before this question is dismissed, let me start by saying I've read the dozens of questions that sound similar. I haven't found anyone that has asked for this specific use case, though, so I'm going to give it a shot.
I would like to create custom images to use (similar to emojis) in a custom keyboard that can be accessed with the globe icon. I understand that I can create a custom keyboard inside my own app, but it will only work within that app. I also understand how the emoji keyboard works.
Is it possible to create a situation where if two people are using the app, though, that the keyboard could be used to input the custom images (emojis) and be viewed only by a receiving user that ALSO has the app - even if the keyboard is being used outside of the custom image keyboard app.
So, basically, there would be a set of images stored within the app and the custom keyboard would reference those images to display whenever the keystroke has been entered and then the receiving phone can locate those images stored within the app to display them (but this could all be done within the native SMS messaging app, not solely in the new custom image keyboard app).
I've researched this a good deal, but can't find a straight answer. Any help or direction would be greatly appreciated!
You could create your own Keyboard that creates somehow special Strings that imply an image. For example could a smiley be encoded like ".CoolSmiley". When you now want to display that text, you should search for patterns you want to recognise. That's how emoji is working. When you type in (y) it will get replaced by a thumb up image because it's recognising the string as a known pattern for a thumb up. This will of course just work inside your app.

Resources