Skip to content

Commit

Permalink
Add application manager frame
Browse files Browse the repository at this point in the history
  • Loading branch information
elliekwon committed Nov 12, 2017
1 parent c2c3e05 commit 9ef4761
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 0 deletions.
2 changes: 2 additions & 0 deletions client/absolute.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,12 @@

import PushManager from './push/push_manager';
import Notification from './notification/notification_manager';
import AppManager from './application/application_manager';
import IndexedDB from './indexeddb/indexeddb';

export default class absolute {
static push: PushManager = new PushManager();
static notification: Notification = new Notification();
static app: AppManager = new AppManager();
static indexeddb: IndexedDB = new IndexedDB();
}
25 changes: 25 additions & 0 deletions client/application/application_manager.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
/**
* Copyright (c) 2017 The Absolute Authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/

declare var navigator: any;

export default class ApplicationManager {

async isCromeBrowser(): Promise<boolean> {

This comment has been minimized.

Copy link
@yjaeseok

yjaeseok Nov 12, 2017

Collaborator

I think this is typo error
You want to check chrome browser, please rename isChromeBrowser()


return false;
}
}
1 change: 1 addition & 0 deletions client/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import absolute from './absolute';
async function main() {
console.log(await absolute.push.register('key'));
console.log(await absolute.push.unregister());
console.log(await absolute.appManager.isCromeBrowser());
}

main();

0 comments on commit 9ef4761

Please sign in to comment.