Fix conversations opening from the background

From a notification, for example, we were opening the inbox but not the
conversation.

// FREEBIE
This commit is contained in:
lilia 2015-09-04 18:33:14 -07:00
parent 24a18e91b3
commit 98aed2975c
2 changed files with 24 additions and 7 deletions

View file

@ -24,7 +24,14 @@
window.location = '/options.html';
} else {
extension.windows.getCurrent(function(appWindow) {
new bg.Whisper.InboxView({appWindow: appWindow}).$el.prependTo(bg.$('body',document));
var view = new bg.Whisper.InboxView({appWindow: appWindow});
view.$el.prependTo(bg.$('body',document));
window.openConversation = function(conversation) {
if (conversation) {
view.openConversation(null, {conversation: conversation});
}
};
openConversation(bg.getOpenConversation());
});
}
});