Hi,
I have come across a couple of little things when porting my patches to plugins, I assumed that these bits just hadn't been done yet in the development. I'm sure you have your own plans but here is what I have found so far….
rcube_plugin->add_texts() always adds texts to the output even in AJAX mode, $OUTPUT->add_label() does not. Adding the texts when the page is loaded to service an AJAX request causes JS errors and an alert box with "error: undefined" pops up.
$OUTPUT->button() always tries to load text from the core localization
array. Is there a better alternative for use in plugins? For example if you
want a button and you give it a label like 'label' => $this->gettext('myplugin')
then on the button you get [My Plugin]
– the
correct text but with [] around it, as it cant be found in the core
localization array.
I think the new API is great apart from those two minor snags. It was really easy to move all my code across. The example plugins really help show what's what as well.
Finally a couple of hook requests:
working on a context menu for the message list and it works great the first time the page is loaded but I can’t see a way in the API to attach the event listener when switching between folders or when a new message arrives.
address book.
Apologies if you are already planning these. I know the code has just been merged to trunk and is still being developed.
Thanks
Phil http://www.tehinterweb.co.uk/roundcube/
On Mon, 20 Apr 2009 00:52:54 +0200, Thomas Bruederli roundcube@gmail.com wrote:
Hello devs and list lurkers
Today we merged the development branch for the upcoming API back into the
trunk. Now you can try out the Plugin API with a fresh checkout from the svn trunk. It is also available as nightly snapshot at http://nightly.roundcube.net/trunk/
It's now time for excessive testing to detect bugs that came in with the code changes for the API. Also the client scripts now rely on jQuery and
we
therefore changed a lot of javascript code. So please let us know if you find some strange behavior or broken buttons.
Regards, Thomas _______________________________________________ List info: http://lists.roundcube.net/dev/
List info: http://lists.roundcube.net/dev/