Smart Ear Redesign

This page is to collect ideas for the redesign of the Smart Ear plugin.

Currently the code is a bit unweildy:

  • Most of the UI is generated by Glade and then converted to something more Pidgin-friendly with a script that calls sed with a bunch of substitutions and deletions.
  • Settings, such as per-group and per-buddy sounds, are stored in a custom-format text file that is read with fscanf().
  • Function names aren't namespaced, which makes it harder to determine what each function does just by looking at its name.

My ideas on a redesign

  • Do a one-time conversion on the file format, if the file reading code is salvagable (i.e. I can wrap my head around it). Once the file is converted, delete it.
  • Store the sound settings on group, contact, and buddy blistnodes with blistnode settings.
  • Use the request API and pluginprefs API (if necessary) to handle all UI elements to avoid needing separate Pidgin and Finch plugins.
    • I tried this, and it's too difficult (maybe impossible) using the request API stuff to get a usable dialog that works in an understandable way. I need the three plugin approach.
    • Currently I am going with a three-plugin approach--an invisible core (libpurple) plugin and UI-specific plugins for Pidgin and Finch.
      • The core plugin simply acts on settings/preferences set by the UI-specific plugins.
      • The UI plugins set preferences and make the blistnode settings being used by the core plugin.
      • The UI plugins will list the core plugin as a dependency so libpurple forces it to load when the UI plugin is loaded.

Comments? Thoughts?

Progress

7/10/07 - The core plugin listed above has been done since Sunday. I need to work on the UI plugins.


Last Modified by jbailey, 17 months ago