Skip to content

Commit

Permalink
Merge pull request #446 from origami-team/v1.0.3-web
Browse files Browse the repository at this point in the history
V1.0.3 web
  • Loading branch information
YouQam authored Nov 17, 2022
2 parents 3466e8b + 8a5fb85 commit d6bee83
Show file tree
Hide file tree
Showing 80 changed files with 228 additions and 169 deletions.
2 changes: 1 addition & 1 deletion android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ android {
applicationId "com.ifgi.geogami"
minSdkVersion rootProject.ext.minSdkVersion
targetSdkVersion 31
versionCode 13
versionCode 14
versionName "1.0.3"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
Expand Down
3 changes: 2 additions & 1 deletion android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@
android:name="com.ifgi.geogami.MainActivity"
android:label="@string/title_activity_main"
android:theme="@style/AppTheme.NoActionBarLaunch"
android:launchMode="singleTask">
android:launchMode="singleTask"
android:exported="true">

<intent-filter>
<action android:name="android.intent.action.MAIN" />
Expand Down
4 changes: 2 additions & 2 deletions android/app/src/main/assets/capacitor.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"bundledWebRuntime": false,
"npmClient": "yarn",
"webDir": "www",
"hideLogs": true,
"server": {
"iosScheme": "https",
"androidScheme": "https"
},
"hideLogs": true
}
}
Binary file modified android/app/src/main/res/drawable-land-hdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-mdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-xhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-xxhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-land-xxxhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-hdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-mdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-xhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-xxhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/drawable-port-xxxhdpi/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 5 additions & 0 deletions android/app/src/main/res/drawable/launch_splash.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<bitmap xmlns:android="http://schemas.android.com/apk/res/android"
android:src="@drawable/splash"
android:scaleType="centerCrop"
/>
Binary file modified android/app/src/main/res/drawable/splash.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added android/app/src/main/res/ic_launcher-web.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-hdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-hdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-mdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-mdpi/ic_launcher_foreground.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Binary file modified android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
Binary file added android/app/src/main/res/playstore-icon.png
2 changes: 1 addition & 1 deletion android/app/src/main/res/values/ic_launcher_background.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="ic_launcher_background">#FFFFFF</color>
<color name="ic_launcher_background">#ffffff</color>
</resources>
1 change: 1 addition & 0 deletions android/app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
<string name="app_name">GeoGami</string>
<string name="title_activity_main">GeoGami</string>
<string name="package_name">com.ifgi.geogami</string>
<string name="fileprovider_authority">com.ifgi.geogami.fileprovider</string>
<string name="custom_url_scheme">com.ifgi.geogami</string>
</resources>
1 change: 0 additions & 1 deletion android/app/src/main/res/xml/file_paths.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<paths xmlns:android="http://schemas.android.com/apk/res/android">
<external-path name="my_images" path="." />
<cache-path name="my_cache_images" path="." />
</paths>
4 changes: 2 additions & 2 deletions capacitor.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"bundledWebRuntime": false,
"npmClient": "yarn",
"webDir": "www",
"hideLogs": true,
"server": {
"iosScheme": "https",
"androidScheme": "https"
},
"hideLogs": true
}
}
4 changes: 2 additions & 2 deletions electron/capacitor.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"bundledWebRuntime": false,
"npmClient": "yarn",
"webDir": "www",
"hideLogs": true,
"server": {
"iosScheme": "https",
"androidScheme": "https"
},
"hideLogs": true
}
}
4 changes: 2 additions & 2 deletions ios/App/App/capacitor.config.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
"bundledWebRuntime": false,
"npmClient": "yarn",
"webDir": "www",
"hideLogs": true,
"server": {
"iosScheme": "https",
"androidScheme": "https"
},
"hideLogs": true
}
}
8 changes: 4 additions & 4 deletions scripts/fixcordova7issue.js.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

module.exports = function (ctx) {

console.log("Attempting To Modify serve-config.js....")
// console.log("Attempting To Modify serve-config.js....")

// Reference Dependencies
var fs = ctx.requireCordovaModule('fs'),
Expand All @@ -20,7 +20,7 @@ module.exports = function (ctx) {
fs.stat(filePath, function (error, stat) {

if (error) {
console.log(error);
// console.log(error);
return;
}

Expand All @@ -42,15 +42,15 @@ module.exports = function (ctx) {
// Loop Through The Lines and Modify the Line/Item if it contains The sourceFileString
for (var i = dataArray.length - 1; i >= 0; i--) {
if (dataArray[i].indexOf(sourceFileString) !== -1) {
console.log('Modifying line:' + dataArray[i]);
// console.log('Modifying line:' + dataArray[i]);
dataArray[i] = targetFileString;
fileModifiedSuccessfully = true;
}
}

// If Nothing Was Found/Removed/Spliced, No Need To Overwrite.
if (!fileModifiedSuccessfully) {
console.log("No Changes to File: " + filePath);
// console.log("No Changes to File: " + filePath);
return;
}

Expand Down
4 changes: 2 additions & 2 deletions src/app/app.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,14 @@ export class AppComponent {
checkInternetConnection() {
// watch network for a disconnection
let disconnectSubscription = this.network.onDisconnect().subscribe(async () => {
//console.log('network was disconnected :-(');
//// console.log('network was disconnected :-(');
this.utilService.setIsOnlineValue(false); // set behaviour sub. false
this.networkAlert = await this.utilService.showToastBtn("No connection", 'dark', null) // show toast
this.networkAlert.present();
});

let connectSubscription = this.network.onConnect().subscribe(() => {
//console.log('network connected!');
//// console.log('network connected!');
this.utilService.setIsOnlineValue(true); // set behaviour sub. true
this.utilService.showToast("Back online", 'success', 3000) // show toast
// Remove notification when connection get back
Expand Down
12 changes: 6 additions & 6 deletions src/app/components/feedback/feedback.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -374,7 +374,7 @@ export class FeedbackComponent {
}

if (this.task.answer.type == AnswerType.DIRECTION) {
// console.log(this.Math.abs(directionBearing - compassHeading));
// // console.log(this.Math.abs(directionBearing - compassHeading));
this.initFeedback(
this.Math.abs(directionBearing - compassHeading) <=
this.DIRECTION_TRESHOLD,
Expand Down Expand Up @@ -525,7 +525,7 @@ export class FeedbackComponent {
) {
const bounds = new mapboxgl.LngLatBounds();
bounds.extend(options.clickPosition);
// console.log(this.lastKnownPosition.coords);
// // console.log(this.lastKnownPosition.coords);
bounds.extend([
this.lastKnownPosition.coords.longitude,
this.lastKnownPosition.coords.latitude,
Expand Down Expand Up @@ -677,7 +677,7 @@ export class FeedbackComponent {
}

public showHint(options: any = undefined) {
// console.log(options);
// // console.log(options);
if (this.task.answer.type == AnswerType.POSITION) {
const waypoint = this.task.answer.position.geometry.coordinates;
const distance = this.helperService.getDistanceFromLatLonInM(
Expand Down Expand Up @@ -718,7 +718,7 @@ export class FeedbackComponent {
this.task.type != "theme-loc"
) {
const center = centroid(this.task.question.geometry.features[0]);
// console.log(center);
// // console.log(center);
const waypoint = options.clickPosition;
const distance = this.helperService.getDistanceFromLatLonInM(
waypoint[1],
Expand All @@ -742,7 +742,7 @@ export class FeedbackComponent {
}

const absClckDir = this.Math.abs(options.clickDirection - evalDirection)
// console.log(absClckDir);
// // console.log(absClckDir);

this.feedback.hint = ""

Expand All @@ -754,7 +754,7 @@ export class FeedbackComponent {
this.feedback.hint =
this.task.answer?.hints?.[2] ?? this.translate.instant("Feedback.directionWrongHint");
}
// console.log(this.feedback.hint);
// // console.log(this.feedback.hint);
this.changeDetectorRef.detectChanges();
}

Expand Down
4 changes: 2 additions & 2 deletions src/app/components/popup/popup.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,11 +17,11 @@ export class PopupComponent implements OnInit {
constructor(public navCtrl: NavController) { }

ngOnInit(): void {
//console.log("gameName: ", this.gameName)
//// console.log("gameName: ", this.gameName)
}

playGame(){
// console.log("play pressed: ", this.gameName)
// // console.log("play pressed: ", this.gameName)
this.navCtrl.navigateForward(`play-game/game-detail/${this.gameID}`);

}
Expand Down
2 changes: 1 addition & 1 deletion src/app/mapControllers/layer-control.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export class LayerControl {
try {
this.map.removeControl(this.styleSwitcherControl);
} catch (e) {
console.log(e);
// console.log(e);
}
if (this.compare != null) {
this.compare.remove();
Expand Down
6 changes: 3 additions & 3 deletions src/app/mapControllers/track-control.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ export class TrackControl {

// keep track permanent impl.
addPermanentTrack(taskId, path = this.path){
// console.log("(track) P index:", taskId,"path: ",path)
// // console.log("(track) P index:", taskId,"path: ",path)
this.map.addSource(`permanentTrack${taskId}`, { type: 'geojson', data: path });
this.map.addLayer({
id: `permanentTrack${taskId}`,
Expand All @@ -127,7 +127,7 @@ export class TrackControl {

// keep track temporary impl.
addTemporaryTrack(taskId, path = this.path){
// console.log("(track) T index:", taskId,"path: ",path)
// // console.log("(track) T index:", taskId,"path: ",path)
this.map.addSource(`temporaryTrack${taskId}`, { type: 'geojson', data: path });
this.map.addLayer({
id: `temporaryTrack${taskId}`,
Expand All @@ -147,7 +147,7 @@ export class TrackControl {
// remove track temporary impl.
removeTemporaryTrack(taskId){
if (this.map.getLayer(`temporaryTrack${taskId}`)) {
// console.log('removeTemporaryTrack/////(track): ', taskId)
// // console.log('removeTemporaryTrack/////(track): ', taskId)
this.map.removeLayer(`temporaryTrack${taskId}`);
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export class AnalyzeGameListPage implements OnInit {
directory: FilesystemDirectory.Documents,
encoding: FilesystemEncoding.UTF8
});
console.log(contents);
// console.log(contents);

this.http.post(`${environment.apiURL}/track`, JSON.parse(contents.data), { observe: 'response' })
.subscribe(response => alert(response.status + ' ' + response.statusText));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ export class CreateFreeTaskModalComponent implements OnInit {
showMarker: true,
};

console.log(this.task);
// console.log(this.task);

// todo --- check it out
// this.settingsChange();
Expand Down
28 changes: 14 additions & 14 deletions src/app/pages/create-game/create-game-list/create-game-list.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ export class CreateGameListPage implements OnInit {
}

});
// console.log("this.gameFactory.game: ", this.gameFactory.game);
// // console.log("this.gameFactory.game: ", this.gameFactory.game);
}

ionViewWillEnter() {
Expand All @@ -86,7 +86,7 @@ export class CreateGameListPage implements OnInit {
// map.addControl(geolocate);
// // let watch = this.geolocation.watchPosition();
// // watch.subscribe((data) => {
// // console.log(data)
// // // console.log(data)
// // });
// // Add geolocate control to the map.
// map.on("load", () => {
Expand All @@ -95,7 +95,7 @@ export class CreateGameListPage implements OnInit {
}

async presentTaskModal(type: string = "nav", task: any = null, isVirtualWorld: boolean = this.isVirtualWorld) {
// console.log(task);
// // console.log(task);

const modal: HTMLIonModalElement = await this.modalController.create({
component:
Expand All @@ -110,7 +110,7 @@ export class CreateGameListPage implements OnInit {

await modal.present();
const { data } = await modal.onWillDismiss();
console.log(data);
// console.log(data);
if (data != undefined) {
if (task != null) {
if (!task._id) {
Expand All @@ -128,32 +128,32 @@ export class CreateGameListPage implements OnInit {
addTaskToGame(task) {
this.game = this.gameFactory.addTask(task);
// this.gameFactory.getGame().then(game => {
// console.log(game)
// // console.log(game)
// this.game = game
// });

console.log(this.game.tasks);
// console.log(this.game.tasks);
}

deleteTask(taskID) {
console.log("deleting", taskID);
// console.log("deleting", taskID);
this.game = this.gameFactory.removeTask(taskID);
}

updateTask(taskID, task) {
console.log("updating", taskID);
// console.log("updating", taskID);
this.game = this.gameFactory.updateTask(taskID, task);
console.log(this.game);
// console.log(this.game);
}

doReorder(ev: any) {
// The `from` and `to` properties contain the index of the item
// when the drag started and ended, respectively
console.log("Dragged from index", ev.detail.from, "to", ev.detail.to);
// console.log("Dragged from index", ev.detail.from, "to", ev.detail.to);

// Before complete is called with the items they will remain in the
// order before the drag
console.log("Before complete", this.game.tasks);
// console.log("Before complete", this.game.tasks);

// Finish the reorder and position the item in the DOM based on
// where the gesture ended. Update the items variable to the
Expand All @@ -162,20 +162,20 @@ export class CreateGameListPage implements OnInit {

this.gameFactory.applyReorder(this.game.tasks);

console.log(this.game.tasks);
// console.log(this.game.tasks);

ev.detail.complete(true);

// After complete is called the items will be in the new order
console.log("After complete", this.game.tasks);
// console.log("After complete", this.game.tasks);
}

toggleReorder() {
this.reorder = !this.reorder;
}

navigateToOverview() {
//console.log("navigate");
//// console.log("navigate");

let bundle = {
isVRWorld: false,
Expand Down
Loading

0 comments on commit d6bee83

Please sign in to comment.