Issue with Worklight Skins laoding on Android tablet - jquery-mobile

I have developed project using worklight 6.1.0 and using jquery-mobile 1.4.2 for UI Related stuff.
I have also implemented the worklight skins and the changes are reflecting properly. But I have two queries related to it as below :
1) What is the correct condition to determine whether it is a “Mobile Phone” or a “Tablet” in getSkinName() function inside “skinLoader.js”.
2) When I install the app on the tablet I see that the UI screens do not load properly and sometimes blank screens are shown and sometimes loading icon is displayed continuously on the display. But if I run the same app on the device I don’t face any such issues. Please find attached screenshots for the same error.
Cannot provide source code for the same. Since its confidential.
Attaching the screen shot for the same.

Because Android is highly fragmented - many different devices and many different resolutions, it is more difficult than with iOS.
I can think of 2 options:
have a minimum resolution that you decide to support in your app and check for it.
This will involves additionally also blocking in the Google Play console to any differences that do not correspond to this size preference.
Use the Cordova device API to retrieve the device's model and verify it is a model that you support. If you support it, show the tablet design, if not - display an alert and close the app or show some placeholder page, etc...
As for the second question, this requires debugging. Without code, this cannot be answered. Either provide code, or submit this specific question as a PMR to IBM and remove it from this Stack Overflow question.

Related

(Automation: Appium\Java) (Xamarin Forms\iOS 13) Elements not visible in tree, after in-app downloads

Summary: We have a Xaamrin Forms iOS\Android application. My goal is to make auto-tests for iOS-app built with Xamarin.IOS 12.10 and Xcode 10.2.1. Builds are made by App Center. Target iOS versions are: 12 and 13. Testing must be performed on real devices, so I not bothered with simulators.
Problem: on devices with iOS 13 element tree contains all elements correctly, i.e. Appium can see all elements and interact with them. But, after "synchronisation" (Which is in-app download of database from server. It's necessary for application to work) element tree reduces just for 2-3, each representing a whole screen. So tests cannot find particular elements and fail. Strangely, but on iOS 12 things go smooth all time whether app made download or not.
Appium versions used:
1.15.1 - on local machine,
1.11 in App Center (though I suppose they've forked it somehow, but it never explicitly said in documentation)
Problem oсcured on both versions.
Questions: How elements can become inaccessible like so in general? What is most probable source of problem in this case particular: iOS, Appium, maybe app itself? Did someone encaunter this or a similar problem? Is there a working solution for it?
Here are links to page sources that I managed to get from tests. I got theese two from same device iPhone XR, iOS 13.3, Appium 1.15.1
Normal Element Tree: https://drive.google.com/open?id=1G82n1xYAxiMQ3q-VV22NXCarM_2dXws3
Element Tree After DB Download: https://drive.google.com/open?id=1nywD3ShSdb1lDbN77mGB6WW018RNjO4F
It looks like its an issue with how Appium is loading the accessibility id's. if you turn on VoiceOver the inspector can again see them. There is an open bug on Xamarin GitHub related to this. Xamarin Forms iOS issue

List of Apple devices using the home indicator?

I'm developing a mobile app and need to know whether or not a home indicator is present on the device I am on (in ios cases). I know that it exists on iPhone X and higher versions. But I can't find out an official list of devices implementing that new feature. Is there one?
That way, I could adapt my UI design according to wether or not the device I detect belongs to that list. (using com.diamonddevgroup.device.Device API)
Just in case, I'm developping using codenameone.
Thanks
I added support for handling that.
Once the update has been approved by Codename One team, update your Device library and call below:
boolean isNotch = Device.isNotch();
You can check the GitHub page for the library here.
And you can follow the status of the library update approval with this pull request. It is approved once its status has changed to Closed.
Leave a comment on this answer or create an issue here if you encounter any problem with the library.
You should definitely be using the safe areas with auto layout to properly layout your views.
But in the case you want to do device specific work, this library is fantastic for knowing about your user's current device.

Adding a URL link to iOS app that is not optimized for mobile platforms (rejection possibility)

I have been doing some research about iOS app approval process, but I can't seem to find one thing that is pretty important in my case. I have added a simple url link to a website (I did not use a web view for the reason I am about to explain).
What I have found is that Apple specifies that font within the app should not be smaller than size 11. They also say that the user should not have to zoom in. Well, unfortunately I have a client who wants me to place a link of her website in a menu section of the app. I told the client that I was concerned that there may be an issue since this website is not optimized for mobile devices. Basically, this link shows a desktop version of a site on a mobile phone.
I have searched online for many guidelines, but I just haven't spotted anything yet. I would guess that they would reject it, but I was just curious if anyone happened to know for sure or knew where I should look to find this out.
Thanks

iOS7 Screen Capture Prevention / Detection

In my iOS app I need either prevent the screenshot capture (by pressing combination of Home +Power button), or need to detect before it saved to the Photo library .
In previous iOS version before taking screenshot touchesCancelled:withEvent this method will called , but iOS7 onwards this wont work.
Apple provide a notification
UIApplicationUserDidTakeScreenshotNotification
for detecting screenshot capture .The real problem is this will fire only after the screenshot is saved in Photo library .
Is there any methods (Private /Public) for detecting screenshot before it happens , or Just prevent the screenshot feature .
Dont consider it as a duplicate question , it is iOS7 specific question
No, nothing has changed since iOS7 and it will not change in the future, it is a conceptual issue, iOS app doesn't has control over the device public functions, consider you turned off 'taking screenshot' while other application needs it!! How this app would know about that?
Best thing you can do is using Configuration Profile as mentioned #QED valid answer.
You can restrict with a Configuration Profile, as described in the linked question.
Check out the Restrictions Payload section, starting on page 27, of the iPhone Configuration Proifile Reference. The key you want is allowScreenShot, described at the bottom of page 30.
Also, the linked reference states that there are a number of ways to install a profile. It may be possible for you to provide, within the app, some method for the user to trigger your server to install/reinstall your profile. Just a thought, I'm not experienced in the matter.
I'm not able to speak to private APIs. You might check out http://www.modmyi.com, or snoop around on IRC for some jailbreak communities. There are lots of experts out there who may be able to point you to the API, but they don't tend to hang on SO.
Good luck!

Writing a replacement "App Launcher" / "Home Screen" for iPad

Is there a way for schools and businesses to replace the iPad "app launcher" or "home screen" with a customized alternative?
Could an application be developed for iOS that would allow this? Or is the SDK locked down to prevent such an application from being developed.
All pointers and insights greatly appreciated.
You can change the load screen, from the dark black to an image ,but no you can't change the layout of the app menu on the iOSDevice. At least not without jail-braking. This is because apple doesn't want you editing their menu that gives them a nice clean look, or see their software.
The app-launcher is not part of the app, it's different even though it's still mainly made with cocoa in objective c, it's still not accessible by you, legally. So since I frown upon jailbraking, and I'm pretty sure most developers do, I would advise to focus on your app, not the main menu which already works great.
Check out ana App launcher definition here.
The sdk is completely locked down, but you could still make a big app, like an app box that has multiple apps inside. The application could be web-based, allowing more access without updating the app, meaning no waiting for apple to approve an update.
One more alternative is that you could make custom apps that are free, and easy for the students or whoever to download them, but they would require a student password to unlock.
Don't edit an OS, it could do serious damage to the device software forever.

Resources