﻿///////////////////////////////////////////////////////////////////////////////
//
//  wcoGooMap.js
//
// © 2007-2009 Wco iEnterprise Solutions Pty Ltd. ALL RIGHTS RESERVED.
// This file is licensed as part of the DataPortal 3.0 Managed Web Presence Solution, for details look here: http://www.wco.com.au
//
///////////////////////////////////////////////////////////////////////////////

///////////////////////////////////////////////////////////////////////////////
/*<remarks>
Method:      constructor
Description: Instantiates a new instance of the pageManager object, making it ready to receive and process calls to the DataPortal Web service.
Parameters:  [none]
</remarks>*/
HtmlGoogleMapObject = function(parentObject, parentElement, googleHtml) {
  this.parent = parentObject;
  this.parentElement = parentElement;
  this.googleHtml = googleHtml;
  
  this.gMap = null;
  this.isInitialised = false;
  
}

//-----------------------------------------------------------------------------
/*<remarks>
  Description: Defines the Class methods.
</remarks>*/
HtmlGoogleMapObject.prototype = {
  init: function() {
    if (this.googleHtml != '') {
      var html = '';
      html += this.googleHtml;
      var newContent = document.createElement('DIV');
      newContent.id = 'newContent';
      newContent.innerHTML = html;
      newContent.style.display = 'none';
      this.gMap = newContent.childNodes[0];
      this.parentElement.appendChild(this.gMap);
    }
    
    this.isInitialised = true;
  }
}

