Skip to content

Commit

Permalink
Merge branch 'master' into imp_6_2
Browse files Browse the repository at this point in the history
  • Loading branch information
slusarz committed Oct 8, 2013
2 parents 7677689 + c5c8abe commit e0dec7e
Show file tree
Hide file tree
Showing 24 changed files with 125 additions and 69 deletions.
2 changes: 1 addition & 1 deletion framework/ActiveSync/lib/Horde/ActiveSync/Device.php
Expand Up @@ -219,4 +219,4 @@ public function save()
$this->_state->setDeviceInfo($this);
}

}
}
4 changes: 1 addition & 3 deletions framework/ActiveSync/lib/Horde/ActiveSync/Imap/Adapter.php
Expand Up @@ -341,7 +341,6 @@ public function getMessageChanges(
$folder->setRemoved($deleted->ids);

if (!empty($options['softdelete']) && !empty($options['sincedate'])) {
$sd = $folder->getSoftDeleteTimes();
$this->_logger->info(sprintf(
'[%s] Polling for SOFTDELETE in %s before %d',
getmypid(), $folder->serverid(), $options['sincedate']));
Expand All @@ -355,8 +354,7 @@ public function getMessageChanges(
$mbox,
$query,
array('results' => array(Horde_Imap_Client::SEARCH_RESULTS_MATCH)));
// @todo change to $search_ret['count'] when Bug: 12682 is fixed
if (count($search_ret['match']->ids)) {
if ($search_ret['count']) {
$this->_logger->info(sprintf('Found %d messages to SOFTDELETE.', count($search_ret['match']->ids)));
$folder->setSoftDeleted($search_ret['match']->ids);
} else {
Expand Down
26 changes: 24 additions & 2 deletions framework/ActiveSync/lib/Horde/ActiveSync/State/Sql.php
Expand Up @@ -492,6 +492,9 @@ public function updateState(
'class' => $change['class'],
'id' => $change['folderuid']);
}
$syncKey = empty($this->_syncKey)
? $this->getLatestSynckeyForCollection($this->_collection['id'])
: $this->_syncKey;

// This is an incoming change from the PIM, store it so we
// don't mirror it back to device.
Expand Down Expand Up @@ -525,7 +528,7 @@ public function updateState(
}
$params = array(
$change['id'],
(empty($this->_syncKey) ? 0 : $this->_syncKey),
$syncKey,
$this->_deviceInfo->id,
$this->_collection['id'],
$user,
Expand All @@ -541,7 +544,7 @@ public function updateState(
$params = array(
$change['id'],
$change['mod'],
empty($this->_syncKey) ? 0 : $this->_syncKey,
$syncKey,
$this->_deviceInfo->id,
$change['serverid'],
$user,
Expand Down Expand Up @@ -1315,6 +1318,25 @@ public function getSyncCache($devid, $user)
}
}

/**
* Return the most recent synckey for the specified collection.
*
* @param string $collection_id The activesync collection id.
*
* @return string|integer The synckey or 0 if not found.
* @since 2.9.0
*/
public function getLatestSynckeyForCollection($collection_id)
{
// For now, pull in the raw cache_data. Will change when each bit of
// data gets it's own field.
$data = $this->getSyncCache($this->_deviceInfo->id, $this->_deviceInfo->user);

return !empty($data['collections'][$collection_id]['lastsynckey'])
? $data['collections'][$collection_id]['lastsynckey']
: 0;
}

/**
* Save the provided sync_cache.
*
Expand Down
26 changes: 19 additions & 7 deletions framework/ActiveSync/package.xml
Expand Up @@ -10,9 +10,9 @@
<email>mrubinsk@horde.org</email>
<active>yes</active>
</lead>
<date>2013-10-02</date>
<date>2013-10-08</date>
<version>
<release>2.8.3</release>
<release>2.8.4</release>
<api>2.8.0</api>
</version>
<stability>
Expand All @@ -21,9 +21,7 @@
</stability>
<license uri="http://www.horde.org/licenses/gpl">GPL-2.0</license>
<notes>
* [mjr] Fix GAL searching for clients that depend on SEARCH_RANGE values.
* [mjr] Fix some authentication issues when certain clients issue broken AutoDiscover requests.
* [mjr] Fix some minor issues with Autodiscover requests caught by unit testing.
*
</notes>
<contents>
<dir baseinstalldir="/" name="/">
Expand Down Expand Up @@ -320,7 +318,7 @@
<package>
<name>Horde_Imap_Client</name>
<channel>pear.horde.org</channel>
<min>2.14.0</min>
<min>2.15.1</min>
<max>3.0.0alpha1</max>
<exclude>3.0.0alpha1</exclude>
</package>
Expand Down Expand Up @@ -1746,13 +1744,27 @@
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-10-02</date>
<date>2013-10-08</date>
<license uri="http://www.horde.org/licenses/gpl">GPL-2.0</license>
<notes>
* [mjr] Fix returning contact image in GAL search for those clients that support it.
* [mjr] Fix GAL searching for clients that depend on SEARCH_RANGE values.
* [mjr] Fix some authentication issues when certain clients issue broken AutoDiscover requests.
* [mjr] Fix some minor issues with Autodiscover requests caught by unit testing.
</notes>
</release>
<release>
<version>
<release>2.8.4</release>
<api>2.8.0</api></version>
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-10-07</date>
<license uri="http://www.horde.org/licenses/gpl">GPL-2.0</license>
<notes>
*
</notes>
</release>
</changelog>
</package>
22 changes: 17 additions & 5 deletions framework/Cache/package.xml
Expand Up @@ -16,9 +16,9 @@
<email>slusarz@horde.org</email>
<active>yes</active>
</lead>
<date>2013-09-17</date>
<date>2013-10-08</date>
<version>
<release>2.3.0</release>
<release>2.3.1</release>
<api>2.3.0</api>
</version>
<stability>
Expand All @@ -27,8 +27,7 @@
</stability>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
* [mms] Fix key expiration for APC, Eaccelerator, and Xcache (Bug #12735).
* [mms] Add Horde_Cache_Storage_Memoryoverlay driver.
*
</notes>
<contents>
<dir baseinstalldir="/" name="/">
Expand Down Expand Up @@ -516,12 +515,25 @@ Initial packaging.
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-09-17</date>
<date>2013-10-08</date>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
* [mms] Fix key expiration for APC, Eaccelerator, and Xcache (Bug #12735).
* [mms] Add Horde_Cache_Storage_Memoryoverlay driver.
</notes>
</release>
<release>
<version>
<release>2.3.1</release>
<api>2.3.0</api></version>
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-10-08</date>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
*
</notes>
</release>
</changelog>
</package>
2 changes: 1 addition & 1 deletion framework/Core/lib/Horde/Config.php
Expand Up @@ -110,7 +110,7 @@ public function __construct($app = 'horde')
* @return array Keys are app names, values are arrays with two keys:
* 'version' and 'url'.
* @throws Horde_Exception
* @throws Horde_Http_Client_Exception
* @throws Horde_Http_Exception, Horde_Exception
*/
public function checkVersions()
{
Expand Down
5 changes: 2 additions & 3 deletions framework/Core/lib/Horde/Core/ActiveSync/Driver.php
Expand Up @@ -2705,8 +2705,7 @@ protected function _searchGal(array $query)
Horde_ActiveSync::GAL_OFFICE => !empty($row['office']) ? $row['office'] : '',
);
if (!empty($query[Horde_ActiveSync_Request_Search::SEARCH_PICTURE])) {
$picture = new Horde_ActiveSync_Message_GalPicture(
array('protocolversion' => $this->_version, 'logger' => $this->_logger));
$picture = Horde_ActiveSync::messageFactory('GalPicture');
if (empty($row['photo'])) {
$picture->status = Horde_ActiveSync_Status::NO_PICTURE;
} elseif (!empty($query[Horde_ActiveSync_Request_Search::SEARCH_MAXPICTURES]) &&
Expand All @@ -2716,7 +2715,7 @@ protected function _searchGal(array $query)
strlen($row['photo']) > $query[Horde_ActiveSync_Request_Search::SEARCH_MAXSIZE]) {
$picture->status = Horde_ActiveSync_Status::PICTURE_TOO_LARGE;
} else {
$picture->data = $row['photo'];
$picture->data = base64_encode($row['photo']['load']['data']);
$picture->status = Horde_ActiveSync_Status::PICTURE_SUCCESS;
++$picture_count;
}
Expand Down
2 changes: 1 addition & 1 deletion framework/Core/lib/Horde/Core/Factory/HttpClient.php
Expand Up @@ -11,7 +11,7 @@ class Horde_Core_Factory_HttpClient extends Horde_Core_Factory_Base
* @param array $opts Configuration options.
*
* @return Horde_Http_Client Client object.
* @throws Horde_Http_Client_Exception
* @throws Horde_Http_Exception
*/
public function create(array $opts = array())
{
Expand Down
30 changes: 18 additions & 12 deletions framework/Core/package.xml
Expand Up @@ -28,9 +28,9 @@
<email>mrubinsk@horde.org</email>
<active>yes</active>
</developer>
<date>2013-09-05</date>
<date>2013-10-08</date>
<version>
<release>2.9.0</release>
<release>2.9.1</release>
<api>2.9.0</api>
</version>
<stability>
Expand All @@ -39,14 +39,7 @@
</stability>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
* [mjr] Send back dummy mail folders when the Mail API is not available (Bug #12738).
* [mms] Upgrade prototype.js to most recent git version (e3d5200cef3236b257ddcfb1eb3eabc5c586bedd).
* [mms] Cache permission results within a PHP access.
* [mms] Don&apos;t initialize unnecessary prefs object when creating the topbar.
* [mjr] Support ActiveSync SOFTDELETE.
* [mms] Respect &apos;nobase64_img&apos; configuration when generating image tags (João Machado &lt;geral@jpaulo.eu&gt;).
* [mjr] Support for X509 certificate authentication in ActiveSync requests.
* [mjr] Fix calculating policy value for SD card encryption and device encryption policies.
*
</notes>
<contents>
<dir baseinstalldir="/" name="/">
Expand Down Expand Up @@ -3160,10 +3153,10 @@
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-09-05</date>
<date>2013-10-08</date>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
* [mjr] Send back dummy mail folders when the Mail API is not available (Bug #12378).
* [mjr] Send back dummy mail folders when the Mail API is not available (Bug #12738).
* [mms] Upgrade prototype.js to most recent git version (e3d5200cef3236b257ddcfb1eb3eabc5c586bedd).
* [mms] Cache permission results within a PHP access.
* [mms] Don&apos;t initialize unnecessary prefs object when creating the topbar.
Expand All @@ -3173,5 +3166,18 @@
* [mjr] Fix calculating policy value for SD card encryption and device encryption policies.
</notes>
</release>
<release>
<version>
<release>2.9.1</release>
<api>2.9.0</api></version>
<stability>
<release>stable</release>
<api>stable</api></stability>
<date>2013-10-08</date>
<license uri="http://www.horde.org/licenses/lgpl21">LGPL-2.1</license>
<notes>
*
</notes>
</release>
</changelog>
</package>
2 changes: 1 addition & 1 deletion framework/Release/lib/Horde/Release/Whups.php
Expand Up @@ -79,7 +79,7 @@ public function addNewVersion($module, $version, $desc = '')
$params = array($id, $version, $desc);
try {
Horde_Rpc::request('jsonrpc', $this->_params['url'], $method, $this->_http, $params);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
throw new Horde_Exception_Wrapped($e);
}
}
Expand Down
2 changes: 1 addition & 1 deletion framework/Rpc/lib/Horde/Rpc/Jsonrpc.php
Expand Up @@ -148,7 +148,7 @@ public static function request($url, $method, $client, $params = null)
$data = Horde_Serialize::serialize($data, Horde_Serialize::JSON);
try {
$result = $client->post($url, $data, $headers);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
throw new Horde_Rpc_Exception($e->getMessage());
}
if ($result->code == 500) {
Expand Down
2 changes: 1 addition & 1 deletion framework/Rpc/lib/Horde/Rpc/Phpgw.php
Expand Up @@ -125,7 +125,7 @@ public static function request($url, $method, $client, $params = null)
'Content-Type', 'text/xml');
try {
$result = $client->post($url, xmlrpc_encode_request($method, $params), $headers);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
throw new Horde_Rpc_Exception($result);
}
if ($result->code != 200) {
Expand Down
2 changes: 1 addition & 1 deletion framework/Rpc/lib/Horde/Rpc/Xmlrpc.php
Expand Up @@ -102,7 +102,7 @@ public static function request($url, $method, $client, $params = null)
'Content-Type' => 'text/xml');
try {
$result = $client->post($url, xmlrpc_encode_request($method, $params), $headers);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
throw new Horde_Rpc_Exception($result);
}
if ($result->code != 200) {
Expand Down
Expand Up @@ -102,7 +102,7 @@ public function upload(array $options = array())
'Content-Length' => strlen($content)
)
);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
throw new Horde_Service_Facebook_Exception(sprintf(Horde_Service_Facebook_Translation::t("Upload failed: %s"), $e->getMessage()));
}

Expand Down Expand Up @@ -130,7 +130,7 @@ public function run()

try {
$result = $this->_http->request($this->_request, $this->_endpoint->toString(true), $params);
} catch (Horde_Http_Client_Exception $e) {
} catch (Horde_Http_Exception $e) {
$this->_facebook->logger->err($e->getMessage());
throw new Horde_Service_Facebook_Exception($e);
}
Expand All @@ -147,4 +147,4 @@ public function run()
return json_decode($result->getBody());
}

}
}
7 changes: 1 addition & 6 deletions horde/themes/default/screen.css
Expand Up @@ -1349,7 +1349,6 @@ div.GrowlerNoticeExit {
background:white none repeat scroll 0 0;
border: 1px solid #d0d0d0;
cursor:default;
/*overflow:hidden;*/
text-align:left;
min-height: 58px;
padding: 4px;
Expand All @@ -1372,15 +1371,11 @@ div.GrowlerNoticeExit {
background:transparent none repeat scroll 0 0;
border:0 none;
display:inline;
outline: none;
position:static;
width:80px;
font-size: 111%;
}
/*.hordeACContainer {
height:18px;
margin:2px;
padding:2px 2px 2px 0;
}*/
.hordeACItemRemove:hover {
cursor:pointer;
}
Expand Down
6 changes: 2 additions & 4 deletions kronolith/config/prefs.php
Expand Up @@ -484,10 +484,8 @@
$ui->prefs['fb_cals']['enum'] = $enum;
},
'on_change' => function() {
$cache = $GLOBALS['injector']->getInstance('Horde_Cache');
$key = 'kronolith.fb.u.' . $GLOBALS['registry']->getAuth();
Horde::debug($key);
$cache->expire($key);
$GLOBALS['injector']->getInstance('Horde_Cache')
->expire('kronolith.fb.u.' . $GLOBALS['registry']->getAuth());
}
);

Expand Down
2 changes: 1 addition & 1 deletion kronolith/js/kronolith.js
Expand Up @@ -6590,7 +6590,7 @@ KronolithCore = {
HordeCore.doAction('poll');
$(kronolithGotoToday).update(Date.today().toString(Kronolith.conf.date_format));
},
6
60
);
}

Expand Down

0 comments on commit e0dec7e

Please sign in to comment.