mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-08-05 16:58:59 +00:00
console.log -> NEWSBLUR.log
This commit is contained in:
parent
bf8f474abf
commit
63c8e0691a
18 changed files with 58 additions and 58 deletions
|
@ -459,7 +459,7 @@ NEWSBLUR.AssetModel = Backbone.Router.extend({
|
|||
if (NEWSBLUR.reader.flags['non_premium_river_view']) {
|
||||
var visible_stories = self.stories.visible().length;
|
||||
var max_stories = NEWSBLUR.reader.constants.RIVER_STORIES_FOR_STANDARD_ACCOUNT;
|
||||
console.log(["checking no more stories", visible_stories, max_stories]);
|
||||
NEWSBLUR.log(["checking no more stories", visible_stories, max_stories]);
|
||||
if (visible_stories >= max_stories) {
|
||||
self.flags['no_more_stories'] = true;
|
||||
self.stories.trigger('no_more_stories');
|
||||
|
@ -1133,7 +1133,7 @@ NEWSBLUR.AssetModel = Backbone.Router.extend({
|
|||
|
||||
follow_user: function(user_id, callback) {
|
||||
this.make_request('/social/follow', {'user_id': user_id}, _.bind(function(data) {
|
||||
console.log(["follow data", data]);
|
||||
NEWSBLUR.log(["follow data", data]);
|
||||
this.user_profile.set(data.user_profile);
|
||||
var following_profile = this.following_profiles.detect(function(profile) {
|
||||
return profile.get('user_id') == data.follow_profile.user_id;
|
||||
|
|
|
@ -14,21 +14,21 @@ NEWSBLUR.Router = Backbone.Router.extend({
|
|||
},
|
||||
|
||||
index: function() {
|
||||
// console.log(["index"]);
|
||||
// NEWSBLUR.log(["index"]);
|
||||
NEWSBLUR.reader.show_splash_page();
|
||||
},
|
||||
|
||||
add_site: function() {
|
||||
console.log(["add", window.location, $.getQueryString('url')]);
|
||||
NEWSBLUR.log(["add", window.location, $.getQueryString('url')]);
|
||||
NEWSBLUR.reader.open_add_feed_modal({url: $.getQueryString('url')});
|
||||
},
|
||||
|
||||
try_site: function() {
|
||||
console.log(["try", window.location]);
|
||||
NEWSBLUR.log(["try", window.location]);
|
||||
},
|
||||
|
||||
site: function(site_id, slug) {
|
||||
// console.log(["site", site_id, slug]);
|
||||
// NEWSBLUR.log(["site", site_id, slug]);
|
||||
site_id = parseInt(site_id, 10);
|
||||
var feed = NEWSBLUR.reader.model.get_feed(site_id);
|
||||
if (feed) {
|
||||
|
@ -41,7 +41,7 @@ NEWSBLUR.Router = Backbone.Router.extend({
|
|||
},
|
||||
|
||||
social: function(user_id, slug) {
|
||||
// console.log(["router:social", user_id, slug]);
|
||||
// NEWSBLUR.log(["router:social", user_id, slug]);
|
||||
var feed_id = "social:" + user_id;
|
||||
if (NEWSBLUR.reader.model.get_feed(feed_id)) {
|
||||
NEWSBLUR.reader.open_social_stories(feed_id, {force: true});
|
||||
|
@ -56,7 +56,7 @@ NEWSBLUR.Router = Backbone.Router.extend({
|
|||
},
|
||||
|
||||
user: function(user) {
|
||||
console.log(["user", user]);
|
||||
NEWSBLUR.log(["user", user]);
|
||||
}
|
||||
|
||||
});
|
|
@ -16,7 +16,7 @@ NEWSBLUR.Models.SocialSubscription = Backbone.Model.extend({
|
|||
},
|
||||
|
||||
on_remove: function() {
|
||||
console.log(["Remove Feed", this, this.views]);
|
||||
NEWSBLUR.log(["Remove Feed", this, this.views]);
|
||||
_.each(this.views, function(view) { view.remove(); });
|
||||
},
|
||||
|
||||
|
|
|
@ -999,7 +999,7 @@
|
|||
var slug = _.string.words(_.string.clean(feed_title.replace(/[^a-z0-9\. ]/ig, ''))).join('-').toLowerCase();
|
||||
var url = "site/" + feed.id + "/" + slug;
|
||||
if (!_.string.include(window.location.pathname, url)) {
|
||||
// console.log(["Navigating to url", url]);
|
||||
// NEWSBLUR.log(["Navigating to url", url]);
|
||||
NEWSBLUR.router.navigate(url);
|
||||
}
|
||||
}
|
||||
|
@ -1008,7 +1008,7 @@
|
|||
|
||||
post_open_feed: function(e, data, first_load) {
|
||||
if (!data) {
|
||||
console.log(["No data from feed, trying again..."]);
|
||||
NEWSBLUR.log(["No data from feed, trying again..."]);
|
||||
return this.open_feed(this.active_feed, {force: true});
|
||||
}
|
||||
var stories = data.stories;
|
||||
|
@ -1257,7 +1257,7 @@
|
|||
// ==================
|
||||
|
||||
open_social_stories: function(feed_id, options) {
|
||||
// console.log(["open_social_stories", feed_id, options]);
|
||||
// NEWSBLUR.log(["open_social_stories", feed_id, options]);
|
||||
options = options || {};
|
||||
if (_.isNumber(feed_id)) feed_id = "social:" + feed_id;
|
||||
|
||||
|
@ -1320,11 +1320,11 @@
|
|||
if (_.string.include(window.location.pathname, "social/" + feed.get('user_id'))) {
|
||||
params['replace'] = true;
|
||||
}
|
||||
// console.log(["Navigating to social", url, window.location.pathname]);
|
||||
// NEWSBLUR.log(["Navigating to social", url, window.location.pathname]);
|
||||
NEWSBLUR.router.navigate(url, params);
|
||||
}
|
||||
} else if (!feed.get('feed_title')) {
|
||||
console.log(["No feed title on social", feed]);
|
||||
NEWSBLUR.log(["No feed title on social", feed]);
|
||||
NEWSBLUR.router.navigate('');
|
||||
}
|
||||
},
|
||||
|
@ -1420,7 +1420,7 @@
|
|||
},
|
||||
|
||||
show_stories_error: function() {
|
||||
console.log(["show_stories_error", arguments]);
|
||||
NEWSBLUR.log(["show_stories_error", arguments]);
|
||||
this.hide_stories_progress_bar();
|
||||
|
||||
NEWSBLUR.app.original_tab_view.iframe_not_busting();
|
||||
|
@ -1463,7 +1463,7 @@
|
|||
if (found_story_in_page === false) {
|
||||
// Story not found, show in feed view with link to page view
|
||||
if (this.story_view == 'page' && !this.flags['page_view_showing_feed_view']) {
|
||||
// console.log(['turn on feed view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
// NEWSBLUR.log(['turn on feed view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
this.flags['page_view_showing_feed_view'] = true;
|
||||
this.flags['feed_view_showing_story_view'] = false;
|
||||
this.switch_taskbar_view('feed', 'page');
|
||||
|
@ -1471,12 +1471,12 @@
|
|||
}
|
||||
} else {
|
||||
if (this.story_view == 'page' && this.flags['page_view_showing_feed_view']) {
|
||||
// console.log(['turn off feed view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
// NEWSBLUR.log(['turn off feed view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
this.flags['page_view_showing_feed_view'] = false;
|
||||
this.flags['feed_view_showing_story_view'] = false;
|
||||
this.switch_taskbar_view('page');
|
||||
} else if (this.flags['feed_view_showing_story_view']) {
|
||||
// console.log(['turn off story view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
// NEWSBLUR.log(['turn off story view', this.flags['page_view_showing_feed_view'], this.flags['feed_view_showing_story_view']]);
|
||||
this.flags['page_view_showing_feed_view'] = false;
|
||||
this.flags['feed_view_showing_story_view'] = false;
|
||||
this.switch_taskbar_view(this.story_view, true);
|
||||
|
@ -2070,7 +2070,7 @@
|
|||
self.flags.scrolling_by_selecting_story_title = false;
|
||||
}, 550);
|
||||
if (view == 'page') {
|
||||
console.log(["iframe_prevented_from_loading", this.flags['iframe_prevented_from_loading']]);
|
||||
NEWSBLUR.log(["iframe_prevented_from_loading", this.flags['iframe_prevented_from_loading']]);
|
||||
if (this.flags['iframe_prevented_from_loading']) {
|
||||
NEWSBLUR.app.original_tab_view.load_feed_iframe();
|
||||
}
|
||||
|
@ -2233,7 +2233,7 @@
|
|||
|
||||
make_manage_menu: function(type, feed_id, story_id, inverse, $item) {
|
||||
var $manage_menu;
|
||||
// console.log(["make_manage_menu", type, feed_id, story_id, inverse, $item]);
|
||||
// NEWSBLUR.log(["make_manage_menu", type, feed_id, story_id, inverse, $item]);
|
||||
|
||||
if (type == 'site') {
|
||||
var show_chooser = !NEWSBLUR.Globals.is_premium && NEWSBLUR.Globals.is_authenticated;
|
||||
|
@ -3304,7 +3304,7 @@
|
|||
$stories_show = $stories_show.not('.NB-feed-story');
|
||||
$stories_hide = $stories_hide.not('.NB-feed-story');
|
||||
}
|
||||
console.log(["single story", $stories_show.length, $stories_hide.length, this.active_story, active_story && active_story.id]);
|
||||
NEWSBLUR.log(["single story", $stories_show.length, $stories_hide.length, this.active_story, active_story && active_story.id]);
|
||||
}
|
||||
|
||||
if (!options['animate']) {
|
||||
|
@ -3369,9 +3369,9 @@
|
|||
// this.socket.refresh_feeds = _.debounce(_.bind(this.force_feeds_refresh, this), 1000*10);
|
||||
this.socket.on('connect', _.bind(function() {
|
||||
var active_feeds = this.send_socket_active_feeds();
|
||||
// console.log(["Connected to real-time pubsub with " + active_feeds.length + " feeds."]);
|
||||
// NEWSBLUR.log(["Connected to real-time pubsub with " + active_feeds.length + " feeds."]);
|
||||
this.socket.on('feed:update', _.bind(function(feed_id, message) {
|
||||
console.log(['Real-time feed update', feed_id, message]);
|
||||
NEWSBLUR.log(['Real-time feed update', feed_id, message]);
|
||||
this.force_feeds_refresh(false, false, feed_id);
|
||||
}, this));
|
||||
|
||||
|
@ -3382,14 +3382,14 @@
|
|||
$('.NB-module-content-account-realtime').attr('title', 'Reticulating splines').removeClass('NB-error');
|
||||
}, this));
|
||||
this.socket.on('disconnect', _.bind(function() {
|
||||
console.log(["Lost connection to real-time pubsub. Falling back to polling."]);
|
||||
NEWSBLUR.log(["Lost connection to real-time pubsub. Falling back to polling."]);
|
||||
this.flags.feed_refreshing_in_realtime = false;
|
||||
this.setup_feed_refresh();
|
||||
$('.NB-module-content-account-realtime-subtitle').html($.make('b', 'Updating every 60 sec'));
|
||||
$('.NB-module-content-account-realtime').attr('title', 'Polling for updates...').addClass('NB-error');
|
||||
}, this));
|
||||
this.socket.on('error', _.bind(function() {
|
||||
console.log(["Can't connect to real-time pubsub."]);
|
||||
NEWSBLUR.log(["Can't connect to real-time pubsub."]);
|
||||
this.flags.feed_refreshing_in_realtime = false;
|
||||
$('.NB-module-content-account-realtime-subtitle').html($.make('b', 'Updating every 60 sec'));
|
||||
$('.NB-module-content-account-realtime').attr('title', 'Polling for updates...').addClass('NB-error');
|
||||
|
@ -3449,11 +3449,11 @@
|
|||
self.model.refresh_feeds(_.bind(function(updated_feeds) {
|
||||
self.post_feed_refresh(updated_feeds);
|
||||
}, self), self.flags['has_unfetched_feeds'], null, function(e) {
|
||||
console.log(["Feed refresh error", e]);
|
||||
NEWSBLUR.log(["Feed refresh error", e]);
|
||||
});
|
||||
}
|
||||
}, refresh_interval);
|
||||
// console.log(["Setting refresh interval to every " + refresh_interval/1000 + " seconds."]);
|
||||
// NEWSBLUR.log(["Setting refresh interval to every " + refresh_interval/1000 + " seconds."]);
|
||||
},
|
||||
|
||||
force_feed_refresh: function(feed_id, new_feed_id) {
|
||||
|
@ -3996,7 +3996,7 @@
|
|||
},
|
||||
|
||||
show_tryfeed_add_button: function() {
|
||||
console.log(["show_tryfeed_add_button", this.$s.$story_taskbar.find('.NB-tryfeed-add:visible').length]);
|
||||
NEWSBLUR.log(["show_tryfeed_add_button", this.$s.$story_taskbar.find('.NB-tryfeed-add:visible').length]);
|
||||
if (this.$s.$story_taskbar.find('.NB-tryfeed-add:visible').length) return;
|
||||
|
||||
var $add = $.make('div', { className: 'NB-modal-submit' }, [
|
||||
|
|
|
@ -199,7 +199,7 @@ _.extend(NEWSBLUR.ReaderAccount.prototype, {
|
|||
select_preferences: function() {
|
||||
var pref = this.model.preference;
|
||||
$('input[name=send_emails]', this.$modal).each(function() {
|
||||
console.log(["pref", pref('send_emails'), $(this).val()]);
|
||||
NEWSBLUR.log(["pref", pref('send_emails'), $(this).val()]);
|
||||
if ($(this).val() == ""+pref('send_emails')) {
|
||||
$(this).attr('checked', true);
|
||||
return false;
|
||||
|
@ -229,7 +229,7 @@ _.extend(NEWSBLUR.ReaderAccount.prototype, {
|
|||
$('.NB-preference-error', this.$modal).text('');
|
||||
$('input[type=submit]', this.$modal).val('Saving...').attr('disabled', true).addClass('NB-disabled');
|
||||
|
||||
console.log(["form['send_emails']", form['send_emails']]);
|
||||
NEWSBLUR.log(["form['send_emails']", form['send_emails']]);
|
||||
this.model.preference('send_emails', form['send_emails']);
|
||||
this.model.save_account_settings(form, function(data) {
|
||||
if (data.code == -1) {
|
||||
|
|
|
@ -7,7 +7,7 @@ NEWSBLUR.ReaderSocialProfile = function(user_id, options) {
|
|||
this.model = NEWSBLUR.assets;
|
||||
this.profiles = new NEWSBLUR.Collections.Users();
|
||||
user_id = parseInt(_.string.ltrim(user_id, 'social:'), 10);
|
||||
console.log(["user_id", user_id]);
|
||||
NEWSBLUR.log(["user_id", user_id]);
|
||||
this.runner(user_id);
|
||||
};
|
||||
|
||||
|
@ -102,7 +102,7 @@ _.extend(NEWSBLUR.ReaderSocialProfile.prototype, {
|
|||
},
|
||||
|
||||
populate_friends: function(data) {
|
||||
console.log(["populate_friends", data, this.profile.get('followers_youknow')]);
|
||||
NEWSBLUR.log(["populate_friends", data, this.profile.get('followers_youknow')]);
|
||||
_.each(['following_youknow', 'following_everybody', 'followers_youknow', 'followers_everybody'], _.bind(function(f) {
|
||||
var user_ids = this.profile.get(f);
|
||||
var $f = $('.NB-profile-'+f.replace('_', '-'), this.$modal);
|
||||
|
|
|
@ -169,7 +169,7 @@ NEWSBLUR.Views.SocialPageLoginView = Backbone.View.extend({
|
|||
},
|
||||
|
||||
post_login: function(data) {
|
||||
console.log(["login data", data]);
|
||||
NEWSBLUR.log(["login data", data]);
|
||||
this.clean();
|
||||
|
||||
window.location.href = this.options.story_url;
|
||||
|
@ -195,7 +195,7 @@ NEWSBLUR.Views.SocialPageLoginView = Backbone.View.extend({
|
|||
},
|
||||
|
||||
post_signup: function(data) {
|
||||
console.log(["signup data", data]);
|
||||
NEWSBLUR.log(["signup data", data]);
|
||||
this.clean();
|
||||
|
||||
window.location.href = this.options.story_url;
|
||||
|
|
|
@ -24,7 +24,7 @@ NEWSBLUR.Views.FeedListHeader = Backbone.View.extend({
|
|||
this.count();
|
||||
}
|
||||
var hide_read_feeds = NEWSBLUR.assets.preference('hide_read_feeds');
|
||||
// console.log(["render feed list header", this.collection.length, this.feeds_count, hide_read_feeds]);
|
||||
// NEWSBLUR.log(["render feed list header", this.collection.length, this.feeds_count, hide_read_feeds]);
|
||||
var $header = _.template('\
|
||||
<div class="NB-feeds-header-dashboard">\
|
||||
<div class="NB-feeds-header-right">\
|
||||
|
|
|
@ -194,7 +194,7 @@ NEWSBLUR.Views.FeedList = Backbone.View.extend({
|
|||
scroll_to_show_selected_feed: function(feed_view) {
|
||||
var $feed_lists = this.$s.$feed_lists;
|
||||
var is_feed_visible = $feed_lists.isScrollVisible(feed_view.$el);
|
||||
// console.log(["scroll_to_show_selected_feed", feed_view, feed_view.$el, is_feed_visible]);
|
||||
// NEWSBLUR.log(["scroll_to_show_selected_feed", feed_view, feed_view.$el, is_feed_visible]);
|
||||
|
||||
if (!is_feed_visible) {
|
||||
var scroll = feed_view.$el.position().top;
|
||||
|
|
|
@ -236,7 +236,7 @@ NEWSBLUR.Views.FeedTitleView = Backbone.View.extend({
|
|||
if (this.options.feed_chooser) return;
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
// console.log(["showing manage menu", this.model.is_social() ? 'socialfeed' : 'feed', $(this.el), this]);
|
||||
// NEWSBLUR.log(["showing manage menu", this.model.is_social() ? 'socialfeed' : 'feed', $(this.el), this]);
|
||||
NEWSBLUR.reader.show_manage_menu(this.model.is_social() ? 'socialfeed' : 'feed', this.$el, {
|
||||
feed_id: this.model.id,
|
||||
toplevel: this.options.depth == 0
|
||||
|
|
|
@ -241,7 +241,7 @@ NEWSBLUR.Views.Folder = Backbone.View.extend({
|
|||
($children.length &&
|
||||
$children.eq(0).is(':visible') &&
|
||||
!this.collection.collapsed)) {
|
||||
console.log(["hiding folder", $children, this.collection, this.options.folder_title]);
|
||||
NEWSBLUR.log(["hiding folder", $children, this.collection, this.options.folder_title]);
|
||||
NEWSBLUR.assets.collapsed_folders(this.options.folder_title, true);
|
||||
this.collection.collapsed = true;
|
||||
this.$el.addClass('NB-folder-collapsed');
|
||||
|
@ -260,7 +260,7 @@ NEWSBLUR.Views.Folder = Backbone.View.extend({
|
|||
// Showing / Expanding
|
||||
else if ($children.length &&
|
||||
(this.collection.collapsed || !$children.eq(0).is(':visible'))) {
|
||||
console.log(["showing folder", this.collection, this.options.folder_title]);
|
||||
NEWSBLUR.log(["showing folder", this.collection, this.options.folder_title]);
|
||||
NEWSBLUR.assets.collapsed_folders(this.options.folder_title, false);
|
||||
this.collection.collapsed = false;
|
||||
this.$el.removeClass('NB-folder-collapsed');
|
||||
|
|
|
@ -186,7 +186,7 @@ NEWSBLUR.Views.OriginalTabView = Backbone.View.extend({
|
|||
NEWSBLUR.reader.story_view == 'story' ||
|
||||
NEWSBLUR.reader.flags['page_view_showing_feed_view']) options.immediate = true;
|
||||
|
||||
// console.log(["Scroll in Original", story.get('story_title'), options]);
|
||||
// NEWSBLUR.log(["Scroll in Original", story.get('story_title'), options]);
|
||||
|
||||
if ($story && $story.length) {
|
||||
if (!options.immediate) {
|
||||
|
@ -415,7 +415,7 @@ NEWSBLUR.Views.OriginalTabView = Backbone.View.extend({
|
|||
this.$el.ready(function() {
|
||||
|
||||
if (feed_id != NEWSBLUR.reader.active_feed) {
|
||||
console.log(["Switched feed, unloading iframe"]);
|
||||
NEWSBLUR.log(["Switched feed, unloading iframe"]);
|
||||
self.unload_feed_iframe();
|
||||
return;
|
||||
}
|
||||
|
@ -580,7 +580,7 @@ NEWSBLUR.Views.OriginalTabView = Backbone.View.extend({
|
|||
var story = this.cache.iframe_story_positions[positions[closest]];
|
||||
if (!story) return;
|
||||
if (story.score() < NEWSBLUR.reader.get_unread_view_score()) return;
|
||||
// console.log(['Scroll iframe', from_top, closest, positions[closest], this.cache.iframe_story_positions[positions[closest]]]);
|
||||
// NEWSBLUR.log(['Scroll iframe', from_top, closest, positions[closest], this.cache.iframe_story_positions[positions[closest]]]);
|
||||
|
||||
if (!story.get('selected')) {
|
||||
story.set('selected', true, {selected_in_original: true, scroll: true, immediate: true});
|
||||
|
@ -601,7 +601,7 @@ NEWSBLUR.Views.OriginalTabView = Backbone.View.extend({
|
|||
}
|
||||
|
||||
var scroll_top = this.$el.contents().scrollTop();
|
||||
// console.log(["mousemove", e, scroll_top, e.pageY]);
|
||||
// NEWSBLUR.log(["mousemove", e, scroll_top, e.pageY]);
|
||||
NEWSBLUR.reader.cache.mouse_position_y = e.pageY - scroll_top;
|
||||
NEWSBLUR.reader.$s.$mouse_indicator.css('top', NEWSBLUR.reader.cache.mouse_position_y - 8);
|
||||
|
||||
|
@ -618,7 +618,7 @@ NEWSBLUR.Views.OriginalTabView = Backbone.View.extend({
|
|||
var positions = this.cache.iframe_story_positions_keys;
|
||||
var closest = $.closest(from_top, positions);
|
||||
var story = this.cache.iframe_story_positions[positions[closest]];
|
||||
// console.log(["mousemove", story, from_top, positions[closest], this.cache.iframe_story_positions]);
|
||||
// NEWSBLUR.log(["mousemove", story, from_top, positions[closest], this.cache.iframe_story_positions]);
|
||||
// this.flags['mousemove_timeout'] = true;
|
||||
if (!story) return;
|
||||
if (story.score() < NEWSBLUR.reader.get_unread_view_score()) {
|
||||
|
|
|
@ -207,7 +207,7 @@ NEWSBLUR.Views.StoryDetailView = Backbone.View.extend({
|
|||
if (onlySelected) return;
|
||||
|
||||
// if (this.model.changedAttributes()) {
|
||||
// console.log(["Story changed", this.model.changedAttributes(), this.model.previousAttributes()]);
|
||||
// NEWSBLUR.log(["Story changed", this.model.changedAttributes(), this.model.previousAttributes()]);
|
||||
// }
|
||||
|
||||
var story = this.model;
|
||||
|
|
|
@ -274,7 +274,7 @@ NEWSBLUR.Views.StoryListView = Backbone.View.extend({
|
|||
models.each(_.bind(function(story) {
|
||||
var image_count = story.story_view.$('.NB-feed-story-content img').length;
|
||||
if (!image_count) {
|
||||
// console.log(["No images", story.get('story_title')]);
|
||||
// NEWSBLUR.log(["No images", story.get('story_title')]);
|
||||
this.flags.feed_view_images_loaded[story.id] = true;
|
||||
} else if (!this.flags.feed_view_images_loaded[story.id]) {
|
||||
// Progressively load the images in each story, so that when one story
|
||||
|
@ -353,7 +353,7 @@ NEWSBLUR.Views.StoryListView = Backbone.View.extend({
|
|||
var story = this.cache.feed_view_story_positions[positions[closest]];
|
||||
|
||||
if (!story) return;
|
||||
// console.log(["Scroll Feed", from_top, offset, position, closest, story.get('story_title')]);
|
||||
// NEWSBLUR.log(["Scroll Feed", from_top, offset, position, closest, story.get('story_title')]);
|
||||
if (!story.get('selected')) {
|
||||
story.set('selected', true, {selected_by_scrolling: true, mouse: true, immediate: true});
|
||||
}
|
||||
|
|
|
@ -272,7 +272,7 @@ NEWSBLUR.Views.StoryShareView = Backbone.View.extend({
|
|||
$share_button_menu.after($error.clone());
|
||||
}
|
||||
this.toggle_feed_story_share_dialog({'resize_open': true});
|
||||
console.log(["post_share_error", data, shared, message, $share_button, $unshare_button, $share_button_menu, $error]);
|
||||
NEWSBLUR.log(["post_share_error", data, shared, message, $share_button, $unshare_button, $share_button_menu, $error]);
|
||||
},
|
||||
|
||||
update_share_button_label: function() {
|
||||
|
@ -333,7 +333,7 @@ NEWSBLUR.Views.StoryShareView = Backbone.View.extend({
|
|||
},
|
||||
|
||||
show_posting_label: function(twitter, facebook) {
|
||||
console.log(["show_posting_label", twitter, facebook]);
|
||||
NEWSBLUR.log(["show_posting_label", twitter, facebook]);
|
||||
var $text = this.$('.NB-sideoption-share-crosspost-text');
|
||||
twitter = twitter || NEWSBLUR.assets.preference('post_to_twitter');
|
||||
facebook = facebook || NEWSBLUR.assets.preference('post_to_facebook');
|
||||
|
|
|
@ -177,7 +177,7 @@ NEWSBLUR.Views.StoryTitleView = Backbone.View.extend({
|
|||
show_manage_menu: function(e) {
|
||||
e.preventDefault();
|
||||
e.stopPropagation();
|
||||
// console.log(["showing manage menu", this.model.is_social() ? 'socialfeed' : 'feed', $(this.el), this]);
|
||||
// NEWSBLUR.log(["showing manage menu", this.model.is_social() ? 'socialfeed' : 'feed', $(this.el), this]);
|
||||
NEWSBLUR.reader.show_manage_menu('story', this.$el, {
|
||||
story_id: this.model.id,
|
||||
feed_id: this.model.get('story_feed_id')
|
||||
|
|
|
@ -102,7 +102,7 @@ NEWSBLUR.Views.StoryTitlesView = Backbone.View.extend({
|
|||
$last.position().top + $last.height() - 13 < container_height))) {
|
||||
if (NEWSBLUR.reader.counts['page_fill_outs'] < NEWSBLUR.reader.constants.FILL_OUT_PAGES &&
|
||||
!NEWSBLUR.assets.flags['no_more_stories']) {
|
||||
// console.log(["fill out", $last.length && $last.position().top, container_height, $last.length, NEWSBLUR.reader.$s.$story_titles.scrollTop()]);
|
||||
// NEWSBLUR.log(["fill out", $last.length && $last.position().top, container_height, $last.length, NEWSBLUR.reader.$s.$story_titles.scrollTop()]);
|
||||
NEWSBLUR.reader.counts['page_fill_outs'] += 1;
|
||||
_.delay(function() {
|
||||
NEWSBLUR.reader.load_page_of_feed_stories({show_loading: false});
|
||||
|
|
|
@ -35,23 +35,23 @@
|
|||
<script type="text/javascript" charset="utf-8">
|
||||
var next = "{{ next|safe }}";
|
||||
if (next) {
|
||||
console.log(["Forwarding to next", next]);
|
||||
NEWSBLUR.log(["Forwarding to next", next]);
|
||||
setTimeout(function() {
|
||||
window.location.href = next;
|
||||
}, 1000);
|
||||
} else if (window.opener && window.opener.NEWSBLUR) {
|
||||
console.log(["Found opener", window.opener.NEWSBLUR]);
|
||||
NEWSBLUR.log(["Found opener", window.opener.NEWSBLUR]);
|
||||
if (window.opener.NEWSBLUR.reader.flags.importing_from_google_reader) {
|
||||
console.log(['Importing from Reader']);
|
||||
NEWSBLUR.log(['Importing from Reader']);
|
||||
if (window.opener.NEWSBLUR.intro) {
|
||||
console.log(['Using Intro dialog']);
|
||||
NEWSBLUR.log(['Using Intro dialog']);
|
||||
window.opener.NEWSBLUR.intro.start_import_from_google_reader({
|
||||
{% if error %}
|
||||
'error': "{{ error }}",
|
||||
{% endif %}
|
||||
});
|
||||
} else {
|
||||
console.log(['Using some other dialog']);
|
||||
NEWSBLUR.log(['Using some other dialog']);
|
||||
window.opener.NEWSBLUR.reader.post_google_reader_connect({
|
||||
{% if error %}
|
||||
'error': "{{ error }}",
|
||||
|
@ -59,14 +59,14 @@
|
|||
});
|
||||
}
|
||||
} else if (window.opener.NEWSBLUR.intro) {
|
||||
console.log(['Connecting through intro']);
|
||||
NEWSBLUR.log(['Connecting through intro']);
|
||||
window.opener.NEWSBLUR.intro.post_connect({
|
||||
{% if error %}
|
||||
'error': "{{ error }}",
|
||||
{% endif %}
|
||||
});
|
||||
} else if (window.opener.NEWSBLUR.reader_friends) {
|
||||
console.log(["Connecting through friends dialog"]);
|
||||
NEWSBLUR.log(["Connecting through friends dialog"]);
|
||||
window.opener.NEWSBLUR.reader_friends.post_connect({
|
||||
{% if error %}
|
||||
'error': "{{ error }}",
|
||||
|
|
Loading…
Add table
Reference in a new issue