--- controlpanel.module	2010-01-16 00:04:56.000000000 -0500
+++ controlpanel.module	2011-09-14 15:21:53.000000000 -0400
@@ -142,7 +142,8 @@ function controlpanel_theme() {
 function theme_controlpanel_panel_view($menu, $block = NULL) {
 
   $content = '';
-  $theme_path = path_to_theme() . '/controlpanel/' . variable_get('controlpanel_icon_size' . $block, '48x48');
+  global $theme_key;
+  $theme_path = drupal_get_path('theme', $theme_key) . '/controlpanel/' . variable_get('controlpanel_icon_size' . $block, '48x48');
 
   if (file_exists($theme_path . '/control_panel_default.png')) {
     $image_directory = $theme_path;
