From b3d38cbabd800bc382debaf0ca17848a67cfd81d Mon Sep 17 00:00:00 2001 From: Mayhem Date: Tue, 2 Jul 2013 18:21:05 +0200 Subject: [PATCH] contextFromLink -> contextFromNode --- src/General/Get.coffee | 2 +- src/Posting/QR.coffee | 2 +- src/Quotelinks/QuoteInline.coffee | 2 +- src/Quotelinks/QuotePreview.coffee | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/General/Get.coffee b/src/General/Get.coffee index f572c10a3..7c8d84cb1 100644 --- a/src/General/Get.coffee +++ b/src/General/Get.coffee @@ -19,7 +19,7 @@ Get = if index then post.clones[index] else post postFromNode: (root) -> Get.postFromRoot $.x 'ancestor::div[contains(@class,"postContainer")][1]', root - contextFromLink: (quotelink) -> + contextFromNode: (quotelink) -> Get.postFromRoot $.x 'ancestor::div[parent::div[@class="thread"]][1]', quotelink postDataFromLink: (link) -> if link.hostname is 'boards.4chan.org' diff --git a/src/Posting/QR.coffee b/src/Posting/QR.coffee index a7d917a64..fb5bce620 100644 --- a/src/Posting/QR.coffee +++ b/src/Posting/QR.coffee @@ -341,7 +341,7 @@ QR = $.addClass QR.nodes.el, 'dump' QR.cooldown.auto = true {com, thread} = QR.nodes - thread.value = Get.contextFromLink(@).thread unless com.value + thread.value = Get.contextFromNode(@).thread unless com.value caretPos = com.selectionStart # Replace selection for text. diff --git a/src/Quotelinks/QuoteInline.coffee b/src/Quotelinks/QuoteInline.coffee index dcff9553c..6a00bdba8 100644 --- a/src/Quotelinks/QuoteInline.coffee +++ b/src/Quotelinks/QuoteInline.coffee @@ -13,7 +13,7 @@ QuoteInline = return if e.shiftKey or e.altKey or e.ctrlKey or e.metaKey or e.button isnt 0 e.preventDefault() {boardID, threadID, postID} = Get.postDataFromLink @ - context = Get.contextFromLink @ + context = Get.contextFromNode @ if $.hasClass @, 'inlined' QuoteInline.rm @, boardID, threadID, postID, context else diff --git a/src/Quotelinks/QuotePreview.coffee b/src/Quotelinks/QuotePreview.coffee index 399bf5ce6..fcd0bfd98 100644 --- a/src/Quotelinks/QuotePreview.coffee +++ b/src/Quotelinks/QuotePreview.coffee @@ -18,7 +18,7 @@ QuotePreview = id: 'qp' className: 'dialog' $.add d.body, qp - Get.postClone boardID, threadID, postID, qp, Get.contextFromLink @ + Get.postClone boardID, threadID, postID, qp, Get.contextFromNode @ UI.hover root: @