From 996878b509ba4e92c55f8ec7eb57d08d809df00f Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 8 Apr 2013 01:20:15 +0200 Subject: [PATCH 1/2] Add a notice that v2 is outdated. --- 4chan_x.user.js | 15 +++++++++++---- script.coffee | 12 +++++++++--- 2 files changed, 20 insertions(+), 7 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index b81f550ce..0d93894a9 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -2690,7 +2690,7 @@ return $.ready(Options.initReady); }, initReady: function() { - var a, setting, settings, _i, _len, _ref; + var a, notice, setting, settings, _i, _len, _ref; _ref = ['navtopright', 'navbotright']; for (_i = 0, _len = _ref.length; _i < _len; _i++) { settings = _ref[_i]; @@ -2702,10 +2702,17 @@ $.on(a, 'click', Options.dialog); setting = $.id(settings); if (Conf['Disable 4chan\'s extension']) { - $.replace(setting.childNodes[1], a); - continue; + $.replace(setting.firstElementChild, a); + } else { + $.prepend(setting, [$.tn('['), a, $.tn('] ')]); } - $.prepend(setting, [$.tn('['), a, $.tn('] ')]); + notice = $.el('a', { + textContent: 'v2 is outdated.', + href: 'https://4chan-x.just-believe.in/', + target: '_blank' + }); + notice.style.color = 'red'; + $.prepend(setting, [$.tn('['), notice, $.tn('] ')]); } if (!$.get('firstrun')) { $.set('firstrun', true); diff --git a/script.coffee b/script.coffee index 16e019089..d9111b150 100644 --- a/script.coffee +++ b/script.coffee @@ -2155,9 +2155,15 @@ Options = $.on a, 'click', Options.dialog setting = $.id settings if Conf['Disable 4chan\'s extension'] - $.replace setting.childNodes[1], a - continue - $.prepend setting, [$.tn('['), a, $.tn('] ')] + $.replace setting.firstElementChild, a + else + $.prepend setting, [$.tn('['), a, $.tn('] ')] + notice = $.el 'a', + textContent: 'v2 is outdated.' + href: 'https://4chan-x.just-believe.in/' + target: '_blank' + notice.style.color = 'red' + $.prepend setting, [$.tn('['), notice, $.tn('] ')] unless $.get 'firstrun' $.set 'firstrun', true # Prevent race conditions From aafe0fcc16d84c4df62b61feb4c5c2f86846bf4c Mon Sep 17 00:00:00 2001 From: Nicolas Stepien Date: Mon, 8 Apr 2013 01:22:17 +0200 Subject: [PATCH 2/2] Release 2.39.3. --- 4chan_x.user.js | 6 +++--- Cakefile | 2 +- changelog | 2 ++ latest.js | 2 +- script.coffee | 2 +- 5 files changed, 8 insertions(+), 6 deletions(-) diff --git a/4chan_x.user.js b/4chan_x.user.js index 0d93894a9..082a82d61 100644 --- a/4chan_x.user.js +++ b/4chan_x.user.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 4chan x -// @version 2.39.2 +// @version 2.39.3 // @namespace aeosynth // @description Adds various features. // @copyright 2009-2011 James Campos @@ -27,7 +27,7 @@ * Copyright (c) 2009-2011 James Campos * Copyright (c) 2012-2013 Nicolas Stepien * http://mayhemydg.github.io/4chan-x/ - * 4chan X 2.39.2 + * 4chan X 2.39.3 * * Permission is hereby granted, free of charge, to any person * obtaining a copy of this software and associated documentation @@ -5822,7 +5822,7 @@ return $.globalEval(("(" + code + ")()").replace('_id_', bq.id)); }, namespace: '4chan_x.', - version: '2.39.2', + version: '2.39.3', callbacks: [], css: '\ /* dialog styling */\ diff --git a/Cakefile b/Cakefile index 29db36039..a96ed378a 100644 --- a/Cakefile +++ b/Cakefile @@ -2,7 +2,7 @@ {exec} = require 'child_process' fs = require 'fs' -VERSION = '2.39.2' +VERSION = '2.39.3' HEADER = """ // ==UserScript== diff --git a/changelog b/changelog index a16722e7a..668d9c853 100644 --- a/changelog +++ b/changelog @@ -1,4 +1,6 @@ master + +2.39.3 - Mayhem Add /fa/ and /s4s/ archive redirection. diff --git a/latest.js b/latest.js index bb4c76a77..deefc42d9 100644 --- a/latest.js +++ b/latest.js @@ -1 +1 @@ -postMessage({version:'2.39.2'},'*') \ No newline at end of file +postMessage({version:'2.39.3'},'*') \ No newline at end of file diff --git a/script.coffee b/script.coffee index d9111b150..96cb6bb09 100644 --- a/script.coffee +++ b/script.coffee @@ -4728,7 +4728,7 @@ Main = $.globalEval "(#{code})()".replace '_id_', bq.id namespace: '4chan_x.' - version: '2.39.2' + version: '2.39.3' callbacks: [] css: ' /* dialog styling */