Available for a limited time only - £10 off a £20 spend at eXpansys! For more details visit this topic!

Please Log In or Register - it's FREE!

 
Reply to this topicStart new topic
 When to initialize/release POOM?, What method on the plug-in should I use?
tedp
post Feb 17 2005, 21:45
Post #1


Newbie
Group Icon

Group: Posters
Posts: 41
Joined: 5th February 2005
Member No.: 108,770

Device(s): Audiovox SMT5600



I'm trying to figure out where to initialize POOM so I can access the Outlook database on a phone. I'm set up with a global variable for the IPOutlookApp pointer and I was figuring to initialize it in myPlugin::Initialize() and release it in the destructor for the plug-in class. What I'm finding as I step through my code is that the IPOutlookApp is uninitialized when I try to access it in myPlugin::OnEvent or other methods.

Looks to me like what I've got there ought to work but it doesn't seem to. Should I take that as a sign that my initialization is failing or that I'm doing the wrong thing by using myPlugin::Initialize()? I'm wondering if the next step for me is to put a static class in place to initialize and release the IPOutlookApp pointer.

Any comments from the more experienced out there?
Go to the top of the page
 
+Quote Post
tedp
post Feb 22 2005, 18:54
Post #2


Newbie
Group Icon

Group: Posters
Posts: 41
Joined: 5th February 2005
Member No.: 108,770

Device(s): Audiovox SMT5600



Well, it took me a while to figure this one out. Turns out that the life cycle of a plug-in looks like this:

1. home.exe loads the homescreen XML
2. home.exe fires off a seperate helper process which loads the plugin dlls and executes myPlugin::Initialize() followed by myPlugin::Save(). This allows the very CPU intensive and memory leak prone XML parsing process to be "someone else's problem" with respect to home.exe. Any plugin state that needs to be saved gets persisted in the Save() method call. The normal constructors and destructors get called as well.
3. home.exe loads the dll and calls myPlugin::Load() to retreive any plugin state saved earlier. Plugin class constructor gets called as well. Plugin message processing loop starts up...
4. Eventually the plugin gets unloaded, probably when home.exe exits upon phone shutdown. Destructors get called.

Microsoft has a nice presentation here which covers it in considerably more detail. Make sure you read the transcripts associated with the presentation too. Those are extremely helpful.

So, net-net is that I need to do any sort of POOM initialization in the constructor for the plugin class or set up a static class that does the necessary work.
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic

Collapse

Similar Topics

  Topic Replies Topic Starter Views Last Action
No New Posts Samsung SGH-i607 flashed with SGH-i600 ROM - Does anybody know how to flash it back?
7 hachete 5,625 Today, 16:02
Last post by: glucklichstas
No new Topic has attachmentsPaul's complete guide to installing OSX Leopard on your MSI Wind / Advent 4211
Video uploading now...
688 Paul (MVP) 303,655 Today, 19:28
Last post by: Paul (MVP)
No new Pinned: Topic has attachmentsHow to adjust your volume levels
The easy way to boost your default volume settings
107 Hendrickson 44,584 Today, 01:51
Last post by: Tulius
No new OMNIA WAS ORANGE, HOW TO UNLOCK HELP
18 martin1234 1,239 Today, 18:32
Last post by: mike1900
No New Posts Is there a way to remove some input methods without modifying the ROM?
5 JacksonZhu 180 Today, 20:28
Last post by: ronaldb3
No New Posts Need new battery, safe place to buy?
0 imzjustplayin 27 Today, 16:27
Last post by: imzjustplayin

1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 


RSS hit counter Lo-Fi Version Time is now: 3rd December 2008 - 20:56

Please visit our 'Plus Partners' - these companies support MoDaCo through 'MoDaCo Plus' - Click Here for more details!

ActiveKitten | Aiko Solutions | Ateksoft | Binaryfish | Conduits | DeveloperOne | eSoft Interactive | FTouchSL | Inesoft | Lingvosoft |

monocube | Mykesoft | OmegaOne | Omnisoft | Opera Software | Resco | SBSH | Slipstream Solutions | SPB Software House |

Splashdata | Sprite Software | Syncdata | Teksoft | VITO | WebIS | z4soft

Would your company like to become a 'Plus Partner'? Click Here to contact us!