mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-21 04:09:55 +09:00
merge from 1.7.3.5(r13153:r13167)
git-svn-id: http://xe-core.googlecode.com/svn/trunk@13168 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
cc47d2b247
commit
2d3f149b5a
2042 changed files with 129266 additions and 126243 deletions
|
|
@ -1,5 +1,7 @@
|
|||
<?php
|
||||
if(!defined('__XE__')) exit();
|
||||
|
||||
if(!defined('__XE__'))
|
||||
exit();
|
||||
|
||||
/**
|
||||
* @file mobile.addon.php
|
||||
|
|
@ -14,37 +16,61 @@ if(!defined('__XE__')) exit();
|
|||
*
|
||||
* after_module_proc > display mobile content
|
||||
* Condition
|
||||
**/
|
||||
* */
|
||||
// Ignore admin page
|
||||
if(Context::get('module')=='admin') return;
|
||||
if(Context::get('module') == 'admin')
|
||||
{
|
||||
return;
|
||||
}
|
||||
// Manage when to call it
|
||||
if($called_position != 'before_module_proc' && $called_position != 'after_module_proc' ) return;
|
||||
if($called_position != 'before_module_proc' && $called_position != 'after_module_proc')
|
||||
{
|
||||
return;
|
||||
}
|
||||
// Ignore if not mobile browser
|
||||
require_once(_XE_PATH_.'addons/mobile/classes/mobile.class.php');
|
||||
if(!mobileXE::getBrowserType()) return;
|
||||
require_once(_XE_PATH_ . 'addons/mobile/classes/mobile.class.php');
|
||||
if(!mobileXE::getBrowserType())
|
||||
{
|
||||
return;
|
||||
}
|
||||
// Generate mobile instance
|
||||
$oMobile = &mobileXE::getInstance();
|
||||
if(!$oMobile) return;
|
||||
if(!$oMobile)
|
||||
{
|
||||
return;
|
||||
}
|
||||
// Specify charset on the add-on settings
|
||||
$oMobile->setCharSet($addon_info->charset);
|
||||
// Set module information
|
||||
$oMobile->setModuleInfo($this->module_info);
|
||||
// Register the current module object
|
||||
$oMobile->setModuleInstance($this);
|
||||
// Extract content and display/exit if navigate mode is or if WAP class exists
|
||||
if($called_position == 'before_module_proc') {
|
||||
|
||||
if($oMobile->isLangChange()) {
|
||||
// Extract content and display/exit if navigate mode is or if WAP class exists
|
||||
if($called_position == 'before_module_proc')
|
||||
{
|
||||
if($oMobile->isLangChange())
|
||||
{
|
||||
$oMobile->setLangType();
|
||||
$oMobile->displayLangSelect();
|
||||
}
|
||||
// On navigation mode, display navigation content
|
||||
if($oMobile->isNavigationMode()) $oMobile->displayNavigationContent();
|
||||
if($oMobile->isNavigationMode())
|
||||
{
|
||||
$oMobile->displayNavigationContent();
|
||||
}
|
||||
// If you have a WAP class content output via WAP class
|
||||
else $oMobile->displayModuleContent();
|
||||
// If neither navigation mode nor WAP class is, display the module's result
|
||||
} else if($called_position == 'after_module_proc') {
|
||||
else
|
||||
{
|
||||
$oMobile->displayModuleContent();
|
||||
}
|
||||
// If neither navigation mode nor WAP class is, display the module's result
|
||||
}
|
||||
else if($called_position == 'after_module_proc')
|
||||
{
|
||||
// Display
|
||||
$oMobile->displayContent();
|
||||
}
|
||||
?>
|
||||
|
||||
/* End of file mobile.addon.php */
|
||||
/* Location: ./addons/mobile/mobile.addon.php */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue