From 284fb9273096e4bc50fb6c4e748bd65a4b609534 Mon Sep 17 00:00:00 2001
From: robocoder <anthon.pang@gmail.com>
Date: Wed, 15 Feb 2012 13:39:24 +0000
Subject: [PATCH] moving admin controller into separate file for (general)
 consistency

git-svn-id: http://dev.piwik.org/svn/trunk@5844 59fd770c-687e-43c8-a1e3-f5a4ff64c105
---
 core/Controller.php       | 26 --------------------------
 core/Controller/Admin.php | 37 +++++++++++++++++++++++++++++++++++++
 2 files changed, 37 insertions(+), 26 deletions(-)
 create mode 100644 core/Controller/Admin.php

diff --git a/core/Controller.php b/core/Controller.php
index 67d799257d..2eb7d20d17 100644
--- a/core/Controller.php
+++ b/core/Controller.php
@@ -728,29 +728,3 @@ abstract class Piwik_Controller
 		}
 	}
 }
-
-/**
- * Parent class of all plugins Controllers with admin functions
- * 
- * @package Piwik
- */
-abstract class Piwik_Controller_Admin extends Piwik_Controller
-{
-	/**
-	 * Used by Admin screens
-	 * 
-	 * @param Piwik_View $view
-	 */
-	protected function setBasicVariablesView($view)
-	{
-		parent::setBasicVariablesView($view);
-
-		$view->currentAdminMenuName = Piwik_GetCurrentAdminMenuName();
-
-		$view->enableFrames = Zend_Registry::get('config')->General->enable_framed_settings;
-		if(!$view->enableFrames)
-		{
-			$view->setXFrameOptions('sameorigin');
-		}
-	}
-}
diff --git a/core/Controller/Admin.php b/core/Controller/Admin.php
new file mode 100644
index 0000000000..1aafd2a9a7
--- /dev/null
+++ b/core/Controller/Admin.php
@@ -0,0 +1,37 @@
+<?php
+/**
+ * Piwik - Open source web analytics
+ * 
+ * @link http://piwik.org
+ * @license http://www.gnu.org/licenses/gpl-3.0.html GPL v3 or later
+ * @version $Id$
+ * 
+ * @category Piwik
+ * @package Piwik
+ */
+
+/**
+ * Parent class of all plugins Controllers with admin functions
+ * 
+ * @package Piwik
+ */
+abstract class Piwik_Controller_Admin extends Piwik_Controller
+{
+	/**
+	 * Used by Admin screens
+	 * 
+	 * @param Piwik_View $view
+	 */
+	protected function setBasicVariablesView($view)
+	{
+		parent::setBasicVariablesView($view);
+
+		$view->currentAdminMenuName = Piwik_GetCurrentAdminMenuName();
+
+		$view->enableFrames = Zend_Registry::get('config')->General->enable_framed_settings;
+		if(!$view->enableFrames)
+		{
+			$view->setXFrameOptions('sameorigin');
+		}
+	}
+}
-- 
GitLab