Simplify currentURL property

This commit is contained in:
Szymon Nowak 2014-06-15 11:44:58 +02:00
parent 6521b09715
commit dabd5dbe9d
4 changed files with 6 additions and 8 deletions

View File

@ -74,7 +74,6 @@
<script src="/scripts/app/controllers/user_controller.js"></script>
<script src="/scripts/app/models/peer.js"></script>
<script src="/scripts/app/models/user.js"></script>
<script src="/scripts/app/views/about_room_view.js"></script>
<script src="/scripts/app/views/file_field.js"></script>
<script src="/scripts/app/views/peer_view.js"></script>
<script src="/scripts/app/views/peer_avatar_view.js"></script>

View File

@ -15,6 +15,10 @@ ShareDrop.App.ApplicationController = Ember.Controller.extend({
this.handlePersonaAuth();
},
currentURL: function () {
return window.location.href;
}.property('currentPath'),
actions: {
signIn: function () {
navigator.id.request();

View File

@ -1,4 +1,4 @@
{{#modal-dialog action="closeModal" currentURL=view.currentURL}}
{{#modal-dialog action="closeModal"}}
<h2 class="logo"><span>ShareDrop</span></h2>
<h3>How rooms work?</h3>
<p>
@ -6,7 +6,7 @@
</p>
<p>
{{input value=view.currentURL disabled="disabled"}}
{{input value=currentURL disabled="disabled"}}
</p>
<div class="actions">

View File

@ -1,5 +0,0 @@
ShareDrop.App.AboutRoomView = Ember.View.extend({
currentURL: function () {
return window.location.href;
}.property()
});