Start a new topic

Json feed & main menu

Json feed & main menu


Hi Marcelo,

if I understand you correct you want to hide the iOS statusbar. Please have a look at the iOS reference. You can also find plenty of answers on stackoverflow to this topic. For example this one deals with hiding the statusbar on iOS 7.

Hope that helps,
Christian


Hi Christian,

I think I phrased that wrongly. The header I would like to remove is the one that holds the current time and battery percentage. For some reason that header is displaying right on top of the app header that contains the Range and Snapshot buttons. Is there any way to remove that one? Or perhaps make the app header display right below the Time-Battery header? The issue is that since this header is displaying right over the app header, I cannot click on either button (Range, Snapshot).

Thanks and sorry for the misunderstanding.

Hi Christian,

I think I phrased that wrongly. The header I would like to remove is the one that holds the current time and battery percentage. For some reason that header is displaying right on top of the app header that contains the Range and Snapshot buttons. Is there any way to remove that one? Or perhaps make the app header display right below the Time-Battery header? The issue is that since this header is displaying right over the app header, I cannot click on either button (Range, Snapshot).

Thanks and sorry for the misunderstanding.

If you don't want to see the header, just remove it from your index.html. I guess you implemented the capture screen feature somewhere else since the buttons are part of the header.

This is the header in the index.html:

<!-- header of UI holding feature buttons -->

<div id ="header-status" data-role="header" data-position="fixed" data-theme="c">

    <a href="javascript: World.showRange();" data-icon="gear" data-inline="true" data-mini="true">Range</a>

    <a href="javascript: World.captureScreen()" data-icon="refresh" >Snapshot</a>

    <h1></h1>

</div>

Hello Christian,

Thank you for that. The application is now up and running. I just have one last detail to deal with. After I removed the tableview, the top header that used to have the "Back" button remained, blocking the header that belongs to the Screen Capture example. I looked through all the css files and could not find the parameter that determines the height of that now irrelevant header. I would like to reduce it or remove it altogether. Thank you in advance.

Regards,

Marcelo

You find the implementation in the file WTScreenshotARViewController.m
This class implements the WTArchitectViewDelegate.

As you can see in the documentation the function (void)architectView:(WTArchitectView *)architectView didCaptureScreenWithContext:(NSDictionary *)context is called when the WTArchitectView finished capturing a screenshot.

Could you please tell me what functions I need to modify to change the main view from example list to "Screen Capture" example?

Regards,

Marcelo

Since the screen capture example implements a callback to the native code, it works only with the native implementation. Please have a look at our documentation where you get a detailed description to each example. Here the direct link to the documentation of the screen capture example.

Hope that helps,
Christian

Hello Christian,

Thanks for that. I managed to solve my issue in Question 1 but am still struggling with 2. As I understand it WTViewController.m loads the current list of examples through WTExamplesManager.m. I tried changing the lines in WTViewController.m to call instead WTScreenshotARViewController.m in order to load the ScreenCapture example but it didn't work. Any help would be greatly appreciated.

Thanks, Marcelo

Hello Marcelo,

Answer to Question 1
Did you debug the webview and check if you get any JavaScript error? Here a link to a description how you can debug your webview on the device.

Answer to Question 2
Have a look at our setup guide for iOS. This might help.

Regards,
Christian

Hello there,

I'm building on top of the "Screen Capture" example from the samples and I'm currently trying to change the json feed the defines de POIs. I've changed the url for POIDATA_SERVER in captureScreen.js but for some reason it's not working.

My second issue refers to the app's main menu. Currently it displays a list with all the different samples available; however I would like to change that so that it automatically opens the "Screen Capture" example on load. It would be great if you could guide as to the files that control that functionality.

Any help would be greatly appreciated.

 

Regards,

Marcelo
Login or Signup to post a comment