2 questions about local android development

Let me first point out that I am a decently experienced sofware engineer. I am quite familiar with OOP principles and software system architecture. My background is mainly in AS3 but I am also sufficiently versed in Java, JavaScript and HTML(5). I thought I'd mention this because it probably makes a difference in the wording of your answer.

Now, the area I am pretty new to is nativa android development. I am currently building an app that will have some simple web integration, i.e. saving and requesting data in/from the cloud using some webservices. I am fairly early in the development stages so it's not too late for fundamental changes in design.

So far, I have simply pressed ahead and built the features as a straight up android/java app with the intent to incorporate a web service manager to get/post the data from/to the cloud. However, I have become aware of the WebView api and now I am wondering if I should stop building all the features in the app itself. Instead, I am thinking it might be a better idea to have the app simply be a wrapper for a WebView which in turn loads a url. That way I could write the actual app as a responsively designed html5 website that automatically adjusts to any screen size it's opened in. If this approach is viable, I am thinking it will mostly eliminate the headaches of developing for different screen sizes. It would also simplify getting/posting data, since it's easier/more tightly integrated to have server communication from a website than building a RESTful system for the app.

So here are my questions:

1) Is what I am describing above - aka building an app to be just a wrapper for a web app that it loads - a viable and smart way to set up an android app? Is it a common way to do this kind of thing?

2) How can I restrict the website/url to be only loadable from inside the app running on an android device and not from a browser running on a computer? Is this possible at all? Are there apis for this kind requirement? I need this to be an android app, not just a website that can be accessed from any platform in any browser.

3) Can anyone point me to a good tutorial/guide on responsive webpage design? I am pretty familiar with the basics but here's what I'm looking for in particular: I have seen responsive webpages that don't just adjust themselves "fluidly" as the browser window is resized (this kind of responsive design I am sufficiently familiar with and can set up easily). What they did instead was to maintain their original (aka biggest) layout until the browser window reached a certain smaller size and then the page snapped into a different layout, perfectly accommodating the smaller size of the browser window. This change included not only the layout but also the number of items visible and the activation of additional UI elements to make navigation in the smaller window easier. Imagine playing cards layed out next to each other in the window. Let's assume 5 cards fit next to each other when the window is in full screen mode. Now imagine the window is decreased in size. The layout stays the same until the first and the last card are almost out of the visible area. As the window gets to that size, the page "snaps" to a different layout, now only displaying the 3 cards in the center with arrows appearing on the left and right edges to signify that there are more cards to which the user can scroll. How is this kind of responsive design done?

Thanks in advance for any relevant replies!


This doesn't answer all your questions... but I'd check out something like PhoneGap, and start there.

Need Your Help

Using $.get to print page Elements

javascript jquery

I'm trying to print the elements of a page using this code:

I can't understand how this function works

c++ function

I have this program and i'm having a very hard time understanding exactly how this function works and why does it do what it does. I think it has something to do with operation precedence, but i'm ...