Posted by robb on January 29, 2009 at 11:35pm
| Project: | Share Buttons (AddToAny) by Lockerz |
| Version: | 6.x-2.0 |
| Component: | Code |
| Category: | task |
| Priority: | normal |
| Assigned: | Unassigned |
| Status: | closed (fixed) |
Issue Summary
I just finished making some changes I required. This ended up getting a wee bit out of hand and I am not quite sure how to submit the changes, which include new files.
- Supports changing the Drupal FEED icon to a AddToAny Feed, same general interface as Share
- Output of Share and Feed are now template driven (tpl files) and receive fully resolved links as well as all components used to create the links
Currently experimental on http://www.canfield.com
Any desire for these changes?
If so how should I submit the changes and the new files (images, .tpl, _shared.admin.in, etc.)
Comments
#1
#2
Robb, you rock, thank you! :) I'm going to get Patrick, the senior/original module dev, to review this and hopefully give you some guidance. I'm from addtoany.com, so if you have any widget-specific questions or thoughts, feel free to get in touch.
After checking out canfield.com, I noticed that the Subscribe button image is set to only 106px, where it should be 120px. Otherwise it's up and running perfectly!
One question:
#3
Thanks!
OK, fixed that image, good catch, thank you. It's attribute dimensions now match image dimensions. It figures the image choice I selected was the only one with a typo! I grabbed all the images from the AddToAny site.
I originally choose a separate module but realized that a lot of code could be factored out (when all is stable), and they are so closely related it seems a bit of waste to have another module. All settings are kept separate, and isolated to a separate admin page. The Share and Subscribe settings are presented as local tabs. I don't think there is any cross over but it does need more testing. The templates to render share and subscribe are different files.
The code for rendering and menu handling is in the main module. I do reuse the CSS so that one CSS file covers both types.
And you can disable the sharing icon from the settings page.
The one area I am no happy about is the way I intercept theme_feed_icon. Someone with more experience than I have in theme overloading may wish to check that out. And when all works, some code factoring is in order. But I started with the goal of making it easy to patch the primary files.
I have attached a TGZ of the code. A patch is a pain to apply with this number of changes. This should be considered experimental maybe even proof-of-concept.
#4
A few minor bug fixes:
- Themers now get width/height as numeric and as attributes (width='...'_), see tpl files for notes
- Correction for image sizes did not get into last TGZ, they are in this one
#5
Some more fixes
- Shared icon is now built properly in all know cases
#6
To reduce the silly - latest version posts - attachments (I wish I could edit/update attachments sometimes) I am hosting the modified package on my site for the time being. The latest version of AddToAny with subscribe support can be found there:
http://www.canfield.com/content/addtoany-subscribe-support
#7
I think the code is stable now, and ready for re-factoring to eliminate redundant elements. Doing this will make patching somewhat harder. I can start this if desired or leave it for others if there are a number of changes pending.
#8
New code available.
- Fixes bug in links when using Share widget on teasers
- A common setup screen for future theme stuff
#9
#10
Is this issue still active ?
#11
Many of these features were incorporated into later versions.
The Subscribe button should eventually be integrated into this module, but sometime after the 7.0 release. Due to the way this module optimizes external script execution, the Share widget and Subscribe widget need careful planning so as not to cause the drop-down menus to mix up.