Applet is blank



Does anyone know why the following code produces a blank applet that is
buggy(panel randomly locks up when right clicking it until I kill it[the 
applet not the panel]).  It seems like it should (and is intended to)
make
an applet with a frame of the demensions of Whatever Height and Width
are.  
Here's the code:

GtkWidget* plugin_applet_new( CICQDaemon* Daemon,
			      const gchar* PluginName,
			      gint Height,
			      gint Width )
{
  /* Create the Applet */
  GtkWidget* Applet = applet_widget_new( ( gchar* )PluginName );
  
  /* Create a Frame */
  GtkWidget* Frame = gtk_frame_new( NULL );

  /* Add the Frame to the Applet */
  applet_widget_add( APPLET_WIDGET( Applet ), Frame );

  /* Set the Shadow Type */
  gtk_frame_set_shadow_type( GTK_FRAME( Frame ), GTK_SHADOW_IN );     

  /* Size the Frame */
  gtk_widget_set_usize( Frame, Width, Height ); 

  /* Create a Fixed Container */
  GtkWidget* Fixed = gtk_fixed_new( );

  /* Add the Fixed Container to the Frame */
  gtk_container_add( GTK_CONTAINER( Frame ), Fixed );

  /* Show the Widgets */
  gtk_widget_show( Fixed );
  gtk_widget_show( Frame );
  gtk_widget_show( Applet );

  return Applet;
}

-- 
Halfline



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]