diff --git a/mobile_tools.module b/mobile_tools.module
index 5823fdf..25386b3 100755
--- a/mobile_tools.module
+++ b/mobile_tools.module
@@ -176,6 +176,15 @@ function mobile_tools_init(){
 }
 
 /**
+* Implements hook_custom_theme().
+*/
+function mobile_tools_custom_theme() {
+  global $mobile_tools_device;
+ 
+  return mobile_tools_switch_theme($mobile_tools_device);
+}
+
+/**
  * Being called in the hook_boot() implementation
  * This function is in charge of redirection or displaying a notification
  * @param $device
@@ -238,11 +247,11 @@ function mobile_tools_switch_theme($device) {
     $mobile_detection_module = variable_get('mobile-tools-device-detection', 'mobile_tools');
     if (variable_get($mobile_detection_module . '_' . $group . '_enable', '') == 1) {
       $custom_theme = variable_get($mobile_detection_module . '_' . $group . '_theme', $conf['theme_default']);
-      return TRUE;
+      return $custom_theme;
     }
     else {
       $custom_theme  = variable_get('mobile_tools_theme_name', $conf['theme_default']);
-      return TRUE;
+      return $custom_theme;
     }
   }
   return FALSE;
