Posted by Rich Rao, Head of global sales, Google Apps for Work
Word processing and spreadsheet programs are the mainstay of office productivity software. Lets face it: without a great way to write memos, crunch numbers and flesh out ideas, you cant get any meaningful work done. For a long time, productivity software was a bit like a midsized sedan: sturdy, dependable, loaded with features and a little dull.
Nine years ago with Google Docs, we saw an opportunity to build something that would enable people to work together in new ways. Fast forward to today and Docs is a productivity powerhouse. Nows a great time to give it a fresh look if you want to take advantage of its unmatched collaboration tools. Weve made it easy by covering most of the features some claim to be missing and adding nifty new stuff like Voice Typing and Explore. All in all, we think youll find its the perfect tool for work.
In fact, were so confident that Docs has all the features you need, without the ones you dont, that were making it even easier to give it a try. If youre worried about switching to Docs because you still have an enterprise agreement (EA) with another provider, well cover the fees of Google Apps until your contract runs out. Well even chip in on some of the deployment costs and set you up for success with one of our Google for Work Partners.
Once your current EA is up, we offer a simple contract with no traps or gotchas. For a lot of businesses, its cheaper, too. Our estimates suggest that businesses with basic EAs and no dependencies can potentially unlock savings of up to 70% by switching to Google Apps for Work.
Theres a new way of working, and we think that once you see Docs and the rest of Google Apps for Work in action, youll never want to go back. We want to help you experience it now, even if youre locked into an existing EA. If youre in the US or Canada, click here now to learn more and see how Google can work for you. If youre outside the US or Canada, stay tuned were actively working to bring this offer to our global markets as well.
To create Custom InfoWindow for Google Maps Android API v2:
- Make your Activity implements GoogleMap.InfoWindowAdapter.
- Override getInfoWindow(Marker marker) and getInfoContents(Marker marker).
The API will first call getInfoWindow(Marker) and if null is returned, it will then call getInfoContents(Marker). If this also returns null, then the default info window will be used. The first of these (getInfoWindow()) allows you to provide a view that will be used for the entire info window. The second of these (getInfoContents()) allows you to just customize the contents of the window but still keep the default info window frame and background.
- setInfoWindowAdapter(this).
Modify MapsActivity.java from last example "Make GoogleMaps marker draggabe and detect moving marker".
public class MapsActivity extends AppCompatActivity implements OnMapReadyCallback, GoogleMap.OnMapClickListener, GoogleMap.OnMapLongClickListener, GoogleMap.OnMarkerDragListener, GoogleMap.InfoWindowAdapter {
private GoogleMap mMap;
@Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_maps); // Obtain the SupportMapFragment and get notified when the map is ready to be used. SupportMapFragment mapFragment = (SupportMapFragment) getSupportFragmentManager() .findFragmentById(R.id.map); mapFragment.getMapAsync(this);
}
/** * Manipulates the map once available. * This callback is triggered when the map is ready to be used. * This is where we can add markers or lines, add listeners or move the camera. In this case, * we just add a marker near Sydney, Australia. * If Google Play services is not installed on the device, the user will be prompted to install * it inside the SupportMapFragment. This method will only be triggered once the user has * installed Google Play services and returned to the app. */ @Override public void onMapReady(GoogleMap googleMap) { mMap = googleMap; mMap.setOnMapClickListener(this); mMap.setOnMapLongClickListener(this); mMap.setOnMarkerDragListener(this); mMap.setInfoWindowAdapter(this); }
@Override public boolean onOptionsItemSelected(MenuItem item) { switch (item.getItemId()) { case R.id.menu_addmarkers: addMarker(); return true; case R.id.maptypeHYBRID: if(mMap != null){ mMap.setMapType(GoogleMap.MAP_TYPE_HYBRID); return true; } case R.id.maptypeNONE: if(mMap != null){ mMap.setMapType(GoogleMap.MAP_TYPE_NONE); return true; } case R.id.maptypeNORMAL: if(mMap != null){ mMap.setMapType(GoogleMap.MAP_TYPE_NORMAL); return true; } case R.id.maptypeSATELLITE: if(mMap != null){ mMap.setMapType(GoogleMap.MAP_TYPE_SATELLITE); return true; } case R.id.maptypeTERRAIN: if(mMap != null){ mMap.setMapType(GoogleMap.MAP_TYPE_TERRAIN); return true; } case R.id.menu_legalnotices: String LicenseInfo = GoogleApiAvailability .getInstance() .getOpenSourceSoftwareLicenseInfo(MapsActivity.this); AlertDialog.Builder LicenseDialog = new AlertDialog.Builder(MapsActivity.this); LicenseDialog.setTitle("Legal Notices"); LicenseDialog.setMessage(LicenseInfo); LicenseDialog.show(); return true; case R.id.menu_about: AlertDialog.Builder aboutDialogBuilder = new AlertDialog.Builder(MapsActivity.this); aboutDialogBuilder.setTitle("About Me") .setMessage("http://android-er.blogspot.com");
aboutDialogBuilder.setPositiveButton("visit", new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { String url = "http://android-er.blogspot.com"; Intent i = new Intent(Intent.ACTION_VIEW); i.setData(Uri.parse(url)); startActivity(i); } });
aboutDialogBuilder.setNegativeButton("Dismiss", new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int which) { dialog.cancel(); } });
try{ lat = Double.parseDouble(strLat); }catch (NumberFormatException ex){ parsable = false; Toast.makeText(MapsActivity.this, "Latitude does not contain a parsable double", Toast.LENGTH_LONG).show(); }
try{ lon = Double.parseDouble(strLon); }catch (NumberFormatException ex){ parsable = false; Toast.makeText(MapsActivity.this, "Longitude does not contain a parsable double", Toast.LENGTH_LONG).show(); }
if(parsable){
LatLng targetLatLng = new LatLng(lat, lon); MarkerOptions markerOptions = new MarkerOptions().position(targetLatLng).title(strTitle);
//Add marker on LongClick position MarkerOptions markerOptions = new MarkerOptions().position(latLng).title(latLng.toString()); markerOptions.draggable(true);
mMap.addMarker(markerOptions); }
@Override public void onMarkerDragStart(Marker marker) { marker.setTitle(marker.getPosition().toString()); marker.showInfoWindow(); marker.setAlpha(0.5f); }
@Override public void onMarkerDrag(Marker marker) { marker.setTitle(marker.getPosition().toString()); marker.showInfoWindow(); marker.setAlpha(0.5f); }
@Override public void onMarkerDragEnd(Marker marker) { marker.setTitle(marker.getPosition().toString()); marker.showInfoWindow(); marker.setAlpha(1.0f); }
We know that with many Google products launching on an array of mobile devices, youre bound to have questions. And with all your experience using those products and devices, youre also likely to have some knowledge to share. Even though weve tried to make our help center as up to date as possible, youll likely have even more questions that we havent addressed yet. We cant talk to everyone -- there are millions of you! -- but weve been working hard to provide you with better ways to express your views and discuss our products. To that end, were very excited to invite you to a housewarming party as our help community moves from Google Groups to a brand new platform: the Google Mobile Help Forum.
The new platform was built from scratch to offer you some exciting new features:
Q&A format to help you find answers quickly
Improved search and integration with the Google Mobile Help Center
Better spam detection and prevention
Public recognition of Top Contributors and frequent posters (with more posting privileges as you make your way up)
Ability to subscribe to ask questions and receive answers via email
Naturally, were pumped for the move. Weve got a dynamic system of levels to reward your contributions, and a profile that you can personalize. You can subscribe to the forum (or to individual discussions) by RSS feed. You can even vote on which responses answer the question best and mark a best answer to a question you asked.
The new forum is just one step in our quest to build better products and connect you with one another, so stay tuned for more. As part of this transition, well archive the current Google Help Group, as well as the Google Mobile Community. We hope youll use the Forum not just when you need help, but also to share your enthusiasm and give tips and tricks to the whole mobile community. So stop by to introduce youself, and stay to ask and answer a few questions.
Posted by Alden and Robin, Google Mobile Help Forum Guides