diff --git a/domain-server/resources/web/js/shared.js b/domain-server/resources/web/js/shared.js
index 3c7dd2705c..ac73cad7d7 100644
--- a/domain-server/resources/web/js/shared.js
+++ b/domain-server/resources/web/js/shared.js
@@ -49,11 +49,11 @@ $.extend(Settings, {
});
var URLs = {
- // STABLE METAVERSE_URL: https://metaverse.highfidelity.com
- // STAGING METAVERSE_URL: https://staging.highfidelity.com
- METAVERSE_URL: 'https://metaverse.highfidelity.com',
- CDN_URL: 'https://cdn.highfidelity.com',
- PLACE_URL: 'https://hifi.place',
+ // STABLE METAVERSE_URL: https://metaverse.highfidelity.com
+ // STAGING METAVERSE_URL: https://staging.highfidelity.com
+ DEFAULT_METAVERSE_URL: "https://metaverse.vircadia.com/live",
+ CDN_URL: 'https://cdn.highfidelity.com',
+ PLACE_URL: 'https://hifi.place',
};
var Strings = {
@@ -61,7 +61,7 @@ var Strings = {
CHOOSE_DOMAIN_BUTTON: "Choose from my domains",
CREATE_DOMAIN_BUTTON: "Create new domain ID",
- CREATE_DOMAIN_SUCCESS_JUST_CONNECTED: "We connnected your High Fidelity account and created a new domain ID for this machine.",
+ CREATE_DOMAIN_SUCCESS_JUST_CONNECTED: "We connnected your Metaverse account and created a new domain ID for this machine.",
CREATE_DOMAIN_SUCCESS: "We created a new domain ID for this machine.",
// When a place modification fails, they will be brought back to the previous
@@ -92,7 +92,7 @@ var Strings = {
ADD_PLACE_LOADING_DIALOG: "Loading your places...",
ADD_PLACE_NOT_CONNECTED_TITLE: "Access token required",
- ADD_PLACE_NOT_CONNECTED_MESSAGE: "You must have an access token to query your High Fidelity places.
Please follow the instructions on the settings page to add an access token.",
+ ADD_PLACE_NOT_CONNECTED_MESSAGE: "You must have an access token to query your Metaverse places.
Please follow the instructions on the settings page to add an access token.",
};
var DOMAIN_ID_TYPE_NONE = 0;
@@ -230,213 +230,212 @@ function getDomainFromAPI(callback) {
function chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAdded) {
if (accessToken) {
+ getMetaverseUrl(function(metaverse_url) {
- var loadingDialog = showLoadingDialog(Strings.ADD_PLACE_LOADING_DIALOG);
+ var loadingDialog = showLoadingDialog(Strings.ADD_PLACE_LOADING_DIALOG);
- function loadPlaces() {
- $.ajax("/api/places", {
- dataType: 'json',
- jsonp: false,
- success: function(data) {
- if (data.status == 'success') {
- var modal_buttons = {
- cancel: {
- label: Strings.ADD_PLACE_CANCEL_BUTTON,
- className: 'add-place-cancel-button btn-default'
- }
- };
+ function loadPlaces() {
+ $.ajax("/api/places", {
+ dataType: 'json',
+ jsonp: false,
+ success: function(data) {
+ if (data.status == 'success') {
+ var modal_buttons = {
+ cancel: {
+ label: Strings.ADD_PLACE_CANCEL_BUTTON,
+ className: 'add-place-cancel-button btn-default'
+ }
+ };
- var dialog;
- var modal_body;
+ var dialog;
+ var modal_body;
+ if (data.data.places.length) {
+ var places_by_id = {};
- if (data.data.places.length) {
- var places_by_id = {};
+ modal_body = $('
"));
+ var currentDomainIDType = getCurrentDomainIDType();
+ if (currentDomainIDType === DOMAIN_ID_TYPE_TEMP) {
+ var warning = "
";
+ warning += "If you choose a place name it will replace your current temporary place name.";
+ warning += "
";
+ modal_body.append(warning);
+ }
- var currentDomainIDType = getCurrentDomainIDType();
- if (currentDomainIDType === DOMAIN_ID_TYPE_TEMP) {
- var warning = "
";
- warning += "If you choose a place name it will replace your current temporary place name.";
- warning += "
";
- modal_body.append(warning);
- }
-
- // setup a select box for the returned places
- modal_body.append($(""));
- place_select = $("");
- _.each(data.data.places, function(place) {
- places_by_id[place.id] = place;
- place_select.append("");
- })
- modal_body.append(place_select);
- modal_body.append($("
This place name already points to a place or path. Saving this would overwrite the previous settings associated with it.
"));
-
- if (forcePathTo === undefined || forcePathTo === null) {
- var path = "
";
- path += "";
- path += "";
- path += "
";
- modal_body.append($(path));
- }
-
- var place_select = modal_body.find("#place-name-select")
- place_select.change(function(ev) {
- var warning = modal_body.find("#place-name-warning");
- var place = places_by_id[$(this).val()];
- if (place === undefined || place.pointee === null) {
- warning.hide();
- } else {
- warning.show();
- }
- });
- place_select.trigger('change');
-
- modal_buttons["success"] = {
- label: Strings.ADD_PLACE_CONFIRM_BUTTON,
- className: 'add-place-confirm-button btn btn-primary',
- callback: function() {
- var placeID = $('#place-name-select').val();
- // set the place ID on the form
- $(Settings.place_ID_SELECTOR).val(placeID).change();
+ // setup a select box for the returned places
+ modal_body.append($(""));
+ place_select = $("");
+ _.each(data.data.places, function(place) {
+ places_by_id[place.id] = place;
+ place_select.append("");
+ })
+ modal_body.append(place_select);
+ modal_body.append($("
This place name already points to a place or path. Saving this would overwrite the previous settings associated with it.
"));
if (forcePathTo === undefined || forcePathTo === null) {
- var placePath = $('#place-path-input').val();
- } else {
- var placePath = forcePathTo;
+ var path = "
";
+ path += "";
+ path += "";
+ path += "
";
+ modal_body.append($(path));
}
- $('.add-place-confirm-button').attr('disabled', 'disabled');
- $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON_PENDING);
- $('.add-place-cancel-button').attr('disabled', 'disabled');
-
- function finalizeSaveDomainID(domainID) {
- var jsonSettings = {
- metaverse: {
- id: domainID
- }
+ var place_select = modal_body.find("#place-name-select")
+ place_select.change(function(ev) {
+ var warning = modal_body.find("#place-name-warning");
+ var place = places_by_id[$(this).val()];
+ if (place === undefined || place.pointee === null) {
+ warning.hide();
+ } else {
+ warning.show();
}
- var dialog = showLoadingDialog("Waiting for Domain Server to restart...");
- $.ajax('/settings.json', {
- data: JSON.stringify(jsonSettings),
- contentType: 'application/json',
- type: 'POST'
- }).done(function(data) {
- if (data.status == "success") {
- waitForDomainServerRestart(function() {
- dialog.modal('hide');
- if (onSuccessfullyAdded) {
- onSuccessfullyAdded(places_by_id[placeID].name, domainID);
- }
- });
- } else {
- bootbox.alert("Failed to add place");
- }
- }).fail(function() {
- bootbox.alert("Failed to add place");
- });
- }
+ });
+ place_select.trigger('change');
- // If domainID is not specified, the current domain id will be used.
- function finishSettingUpPlace(domainID) {
- sendUpdatePlaceRequest(
- placeID,
- placePath,
- domainID,
- false,
- function(data) {
- dialog.modal('hide')
- if (domainID) {
- $(Settings.DOMAIN_ID_SELECTOR).val(domainID).change();
- finalizeSaveDomainID(domainID);
- } else {
- if (onSuccessfullyAdded) {
- onSuccessfullyAdded(places_by_id[placeID].name);
+ modal_buttons["success"] = {
+ label: Strings.ADD_PLACE_CONFIRM_BUTTON,
+ className: 'add-place-confirm-button btn btn-primary',
+ callback: function() {
+ var placeID = $('#place-name-select').val();
+ // set the place ID on the form
+ $(Settings.place_ID_SELECTOR).val(placeID).change();
+
+ if (forcePathTo === undefined || forcePathTo === null) {
+ var placePath = $('#place-path-input').val();
+ } else {
+ var placePath = forcePathTo;
+ }
+
+ $('.add-place-confirm-button').attr('disabled', 'disabled');
+ $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON_PENDING);
+ $('.add-place-cancel-button').attr('disabled', 'disabled');
+
+ function finalizeSaveDomainID(domainID) {
+ var jsonSettings = {
+ metaverse: {
+ id: domainID
}
}
- },
- function(data) {
- $('.add-place-confirm-button').removeAttr('disabled');
- $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON);
- $('.add-place-cancel-button').removeAttr('disabled');
- bootbox.alert(Strings.ADD_PLACE_UNKNOWN_ERROR);
+ var dialog = showLoadingDialog("Waiting for Domain Server to restart...");
+ $.ajax('/settings.json', {
+ data: JSON.stringify(jsonSettings),
+ contentType: 'application/json',
+ type: 'POST'
+ }).done(function(data) {
+ if (data.status == "success") {
+ waitForDomainServerRestart(function() {
+ dialog.modal('hide');
+ if (onSuccessfullyAdded) {
+ onSuccessfullyAdded(places_by_id[placeID].name, domainID);
+ }
+ });
+ } else {
+ bootbox.alert("Failed to add place");
+ }
+ }).fail(function() {
+ bootbox.alert("Failed to add place");
+ });
}
- );
- }
- function maybeCreateNewDomainID() {
- console.log("Maybe creating domain id", currentDomainIDType)
- if (currentDomainIDType === DOMAIN_ID_TYPE_FULL) {
- finishSettingUpPlace();
- } else {
- sendCreateDomainRequest(function(domainID) {
- console.log("Created domain", domainID);
- finishSettingUpPlace(domainID);
- }, function() {
- $('.add-place-confirm-button').removeAttr('disabled');
- $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON);
- $('.add-place-cancel-button').removeAttr('disabled');
- bootbox.alert(Strings.ADD_PLACE_UNKNOWN_ERROR);
- });
+ // If domainID is not specified, the current domain id will be used.
+ function finishSettingUpPlace(domainID) {
+ sendUpdatePlaceRequest(
+ placeID,
+ placePath,
+ domainID,
+ false,
+ function(data) {
+ dialog.modal('hide')
+ if (domainID) {
+ $(Settings.DOMAIN_ID_SELECTOR).val(domainID).change();
+ finalizeSaveDomainID(domainID);
+ } else {
+ if (onSuccessfullyAdded) {
+ onSuccessfullyAdded(places_by_id[placeID].name);
+ }
+ }
+ },
+ function(data) {
+ $('.add-place-confirm-button').removeAttr('disabled');
+ $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON);
+ $('.add-place-cancel-button').removeAttr('disabled');
+ bootbox.alert(Strings.ADD_PLACE_UNKNOWN_ERROR);
+ }
+ );
+ }
+
+ function maybeCreateNewDomainID() {
+ console.log("Maybe creating domain id", currentDomainIDType)
+ if (currentDomainIDType === DOMAIN_ID_TYPE_FULL) {
+ finishSettingUpPlace();
+ } else {
+ sendCreateDomainRequest(function(domainID) {
+ console.log("Created domain", domainID);
+ finishSettingUpPlace(domainID);
+ }, function() {
+ $('.add-place-confirm-button').removeAttr('disabled');
+ $('.add-place-confirm-button').html(Strings.ADD_PLACE_CONFIRM_BUTTON);
+ $('.add-place-cancel-button').removeAttr('disabled');
+ bootbox.alert(Strings.ADD_PLACE_UNKNOWN_ERROR);
+ });
+ }
+ }
+
+ maybeCreateNewDomainID();
+
+ return false;
}
}
-
- maybeCreateNewDomainID();
-
- return false;
+ } else {
+ modal_buttons["success"] = {
+ label: Strings.ADD_PLACE_NO_PLACES_BUTTON,
+ callback: function() {
+ window.open(metaverse_url + "/user/places", '_blank');
+ }
+ }
+ modal_body = Strings.ADD_PLACE_NO_PLACES_MESSAGE;
}
+ dialog = bootbox.dialog({
+ title: Strings.ADD_PLACE_TITLE,
+ message: modal_body,
+ closeButton: false,
+ buttons: modal_buttons,
+ onEscape: true
+ });
+ } else {
+ bootbox.alert(Strings.ADD_PLACE_UNABLE_TO_LOAD_ERROR);
}
- } else {
- modal_buttons["success"] = {
- label: Strings.ADD_PLACE_NO_PLACES_BUTTON,
- callback: function() {
- window.open(URLs.METAVERSE_URL + "/user/places", '_blank');
- }
- }
- modal_body = Strings.ADD_PLACE_NO_PLACES_MESSAGE;
- }
-
- dialog = bootbox.dialog({
- title: Strings.ADD_PLACE_TITLE,
- message: modal_body,
- closeButton: false,
- buttons: modal_buttons,
- onEscape: true
- });
- } else {
- bootbox.alert(Strings.ADD_PLACE_UNABLE_TO_LOAD_ERROR);
- }
- },
- error: function() {
- bootbox.alert(Strings.ADD_PLACE_UNABLE_TO_LOAD_ERROR);
- },
- complete: function() {
- loadingDialog.modal('hide');
- }
- });
- }
-
- var domainType = getCurrentDomainIDType();
- if (domainType !== DOMAIN_ID_TYPE_UNKNOWN) {
- loadPlaces();
- } else {
- getDomainFromAPI(function(data) {
- if (data.status === 'success') {
- var domainType = getCurrentDomainIDType();
- loadPlaces();
- } else {
- loadingDialog.modal('hide');
- bootbox.confirm("We were not able to load your domain information from the Metaverse. Would you like to retry?", function(response) {
- if (response) {
- chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAdded);
+ },
+ error: function() {
+ bootbox.alert(Strings.ADD_PLACE_UNABLE_TO_LOAD_ERROR);
+ },
+ complete: function() {
+ loadingDialog.modal('hide');
}
});
}
- })
- }
+ var domainType = getCurrentDomainIDType();
+ if (domainType !== DOMAIN_ID_TYPE_UNKNOWN) {
+ loadPlaces();
+ } else {
+ getDomainFromAPI(function(data) {
+ if (data.status === 'success') {
+ var domainType = getCurrentDomainIDType();
+ loadPlaces();
+ } else {
+ loadingDialog.modal('hide');
+ bootbox.confirm("We were not able to load your domain information from the Metaverse. Would you like to retry?", function(response) {
+ if (response) {
+ chooseFromHighFidelityPlaces(accessToken, forcePathTo, onSuccessfullyAdded);
+ }
+ });
+ }
+ })
+ }
+ });
} else {
bootbox.alert({
title: Strings.ADD_PLACE_NOT_CONNECTED_TITLE,
@@ -502,13 +501,13 @@ function prepareAccessTokenPrompt(callback) {
}
function getMetaverseUrl(callback) {
- $.ajax('/api/metaverse_info', {
- success: function(data) {
- callback(data.metaverse_url);
- },
- error: function() {
- callback(URLs.METAVERSE_URL);
- }
+ $.ajax('/domain/metaverse_info', {
+ success: function(data) {
+ callback(data.metaverse.metaverse_url);
+ },
+ error: function() {
+ callback(URLs.DEFAULT_METAVERSE_URL);
+ }
});
}
diff --git a/domain-server/resources/web/settings/js/settings.js b/domain-server/resources/web/settings/js/settings.js
index e8c04fa2be..b1e975bc6c 100644
--- a/domain-server/resources/web/settings/js/settings.js
+++ b/domain-server/resources/web/settings/js/settings.js
@@ -16,7 +16,7 @@ $(document).ready(function(){
Settings.extraGroupsAtEnd = Settings.extraDomainGroupsAtEnd;
Settings.extraGroupsAtIndex = Settings.extraDomainGroupsAtIndex;
- var METAVERSE_URL = URLs.METAVERSE_URL;
+ var METAVERSE_URL = URLs.DEFAULT_METAVERSE_URL;
var SSL_PRIVATE_KEY_FILE_ID = 'ssl-private-key-file';
var SSL_PRIVATE_KEY_CONTENTS_ID = 'key-contents';
@@ -277,7 +277,7 @@ $(document).ready(function(){
swal({
title: '',
type: 'error',
- text: "There was a problem retrieving domain information from High Fidelity API.",
+ text: "There was a problem retrieving domain information from the Metaverse API.",
confirmButtonText: 'Try again',
showCancelButton: true,
closeOnConfirm: false
@@ -306,7 +306,7 @@ $(document).ready(function(){
if (hasAccessToken) {
el = "
";
- el += "High Fidelity Account Connected";
+ el += "Metaverse Account Connected";
el += "";
el += "
";
el = $(el);
@@ -319,7 +319,7 @@ $(document).ready(function(){
}
buttonSetting.help = "";
buttonSetting.classes = "btn-primary";
- buttonSetting.button_label = "Connect High Fidelity Account";
+ buttonSetting.button_label = "Connect Metaverse Account";
buttonSetting.html_id = Settings.CONNECT_ACCOUNT_BTN_ID;
buttonSetting.href = METAVERSE_URL + "/user/tokens/new?for_domain_server=true";
@@ -713,7 +713,7 @@ $(document).ready(function(){
html_id: Settings.PLACES_TABLE_ID,
help: "The following places currently point to this domain.To point places to this domain, "
+ " go to the My Places "
- + "page in your High Fidelity Metaverse account.",
+ + "page in your Metaverse account.",
read_only: true,
can_add_new_rows: false,
columns: [
@@ -997,7 +997,7 @@ $(document).ready(function(){
if (data.data.domains.length) {
// setup a select box for the returned domains
- modal_body = "
Choose the High Fidelity domain you want this domain-server to represent. This will set your domain ID on the settings page.
";
+ modal_body = "
Choose the Metaverse domain you want this domain-server to represent. This will set your domain ID on the settings page.
You do not have any domains in your High Fidelity account." +
+ modal_body = "
You do not have any domains in your Metaverse account." +
"
Go to your domains page to create a new one. Once your domain is created re-open this dialog to select it.
"
}
@@ -1038,7 +1038,7 @@ $(document).ready(function(){
})
},
error: function() {
- bootbox.alert("Failed to retrieve your domains from the High Fidelity Metaverse");
+ bootbox.alert("Failed to retrieve your domains from the Metaverse");
},
complete: function() {
// remove the spinner from the choose button
@@ -1049,7 +1049,7 @@ $(document).ready(function(){
} else {
bootbox.alert({
- message: "You must have an access token to query your High Fidelity domains.
" +
+ message: "You must have an access token to query your Metaverse domains.
" +
"Please follow the instructions on the settings page to add an access token.",
title: "Access token required"
})
diff --git a/domain-server/resources/web/wizard/index.shtml b/domain-server/resources/web/wizard/index.shtml
index 37f9d9e813..e81579c1f5 100644
--- a/domain-server/resources/web/wizard/index.shtml
+++ b/domain-server/resources/web/wizard/index.shtml
@@ -3,12 +3,12 @@
- By connecting your High Fidelity Account you will be granting access to your account information.
+ By connecting your Metaverse Account you will be granting access to your account information.
Place names are similar to web addresses. Users who want to visit your domain can
- enter its Place Name in High Fidelity's Interface. You can choose a Place Name for your domain.
+ enter its Place Name in Vircadia's Interface. You can choose a Place Name for your domain.
Your domain may also be reachable by IP address.
@@ -56,11 +56,11 @@
-
Localhost has been granted administrator privileges to this domain. (Localhost is anyuser on the same machine as the High Fidelity Server)
+
Localhost has been granted administrator privileges to this domain. (Localhost is anyuser on the same machine as the Vircadia Server)
- Add your High Fidelity username and any other usernames to grant administrator privileges
+ Add your Metaverse username and any other usernames to grant administrator privileges
@@ -95,7 +95,7 @@
@@ -126,7 +126,7 @@
@@ -164,14 +164,14 @@
Username
- This does not have to be your High Fidelity username
+ This does not have to be your Metaverse username
Enter password
- This should not be the same as your High Fidelity password
+ This should not be the same as your Metaverse password
diff --git a/domain-server/resources/web/wizard/js/wizard.js b/domain-server/resources/web/wizard/js/wizard.js
index efd3b28116..51b243fff8 100644
--- a/domain-server/resources/web/wizard/js/wizard.js
+++ b/domain-server/resources/web/wizard/js/wizard.js
@@ -5,7 +5,7 @@ var Metaverse = {
var currentStepNumber;
$(document).ready(function(){
- Strings.ADD_PLACE_NOT_CONNECTED_MESSAGE = "You must have an access token to query your High Fidelity places.
" +
+ Strings.ADD_PLACE_NOT_CONNECTED_MESSAGE = "You must have an access token to query your Metaverse places.
" +
"Please go back and connect your account.";
$('#connect-account-btn').attr('href', URLs.METAVERSE_URL + "/user/tokens/new?for_domain_server=true");
@@ -15,9 +15,9 @@ $(document).ready(function(){
$('.perms-link').on('click', function() {
var modal_body = '
';
modal_body += 'None - No one will have permissions. Only you and the users your have given administrator privileges to will have permissions.';
- modal_body += 'Friends - Users who are your Friends in High Fidelity.';
- modal_body += 'Users logged into High Fidelity - Users who are currently logged into High Fidelity.';
- modal_body += 'Everyone - Anyone who uses High Fidelity.';
+ modal_body += 'Friends - Users who are your Friends in the Metaverse.';
+ modal_body += 'Users logged into the Metaverse - Users who are currently logged into the Metaverse.';
+ modal_body += 'Everyone - Anyone who uses the Metaverse.';
modal_body += '
';
dialog = bootbox.dialog({
@@ -142,7 +142,7 @@ function setupWizardSteps() {
});
$('#permissions-description').html('You have been assigned administrator privileges to this domain.');
- $('#admin-description').html('Add more High Fidelity usernames');
+ $('#admin-description').html('Add more Metaverse usernames');
} else {
$('.cloud-only').remove();
$('#save-permissions').text("Finish");