Closed (fixed)
Project:
Advanced Forum
Version:
6.x-2.x-dev
Component:
User interface
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
5 Dec 2010 at 21:11 UTC
Updated:
30 Oct 2011 at 00:49 UTC
Jump to comment: Most recent file
Comments
Comment #1
michelleI don't know javascript but I'd be happy to add this if someone can do a patch.
Michelle
Comment #2
Michsk commentedwill do.
Comment #3
michelleAre you still planning on doing this?
Michelle
Comment #4
Michsk commentedYes, this week.
Comment #5
Michsk commentedwill do this today.
Comment #6
Michsk commentedHere's the js
Comment #7
michelleThanks, will have a look soon as i can.
Will changing advForumFocus to AdvancedForumFocus hurt anything? Pet peeve but I don't like that abbreviation and have removed it from the rest of the code.
Michelle
Comment #8
Michsk commentedthat's no problem.
Comment #9
michelleI'm going to add this after alpha 4. Sorry for that but alpha 4 has been delayed for so long that I have to be strict at this point. Nothing that isn't a bug fix is going in until I get that release out, even if it's a ready to go patch. I can't risk introducing new bugs while I'm trying to clean up the remaining ones.
Michelle
Comment #10
mcdruid commentedI thought this was going to be a quick one, but it's not turned out to be...
AFAICS the existing js/advanced_forum.js file is entirely concerned with the collapsible containers functionality. It only gets added by the preprocess function for topic_lists and it's not obvious (to me at least) how behaviours for totally unrelated functionality like this could be added to it cleanly.
So, I've added a new file js/advanced_forum_node.js which gets added by the preprocess function for nodes (it would be too messy to start messing with the existing file / code to make the namespaces consistent, IMHO so I'm leaving all that as is).
I've added lasac's new Drupal behavior in this file. I had to modify it a little though in order to accommodate some of the different configurations that could be in place. i.e.
* don't do anything if the comment form is on a separate page (otherwise breaks the reply links)
* if comment subjects are enabled, focus the subject textfield rather than the comment textarea
I'm attaching this as a patch for further review rather than committing it straight away - feedback welcomed.
Comment #11
mcdruid commentedI reviewed this again, and realised it needed to be adapted for nodecomment, where the ids in the form will be different.
It should now work with and without nodecomment.
Committed to 6.x-2.x branch.
Thanks for the original work lasac, and sorry it took so long to get in.
Comment #12
Michsk commentedNo problem. Thanks for commiting.
I had more work with the theme for advanced forum, for which there is zero info about commiting or not. Maybe you could shine some light on that? Would be great to have it come standard with AF