diff options
author | Michael Gapczynski <mtgap@owncloud.com> | 2012-07-25 17:08:18 -0400 |
---|---|---|
committer | Michael Gapczynski <mtgap@owncloud.com> | 2012-07-25 17:08:18 -0400 |
commit | 30b58f56771aa54304069d40a62070c06f5308fc (patch) | |
tree | e0bb2bba21c561f96d27bb9cfc09d714aa21d332 /apps/gallery/lib | |
parent | 4d17ed2f71c8cbb0d34c039aa7953b2427ce5c78 (diff) | |
parent | f25ccaff59c135d7f1f22196bf266916ef131b35 (diff) | |
download | nextcloud-server-30b58f56771aa54304069d40a62070c06f5308fc.tar.gz nextcloud-server-30b58f56771aa54304069d40a62070c06f5308fc.zip |
Merge branch 'master' into share_api
Conflicts:
apps/calendar/js/loader.js
apps/contacts/index.php
apps/contacts/js/loader.js
apps/files/js/files.js
apps/files_sharing/sharedstorage.php
lib/filesystemview.php
Diffstat (limited to 'apps/gallery/lib')
-rw-r--r-- | apps/gallery/lib/album.php | 2 | ||||
-rw-r--r-- | apps/gallery/lib/managers.php | 1 | ||||
-rw-r--r-- | apps/gallery/lib/share.php | 42 | ||||
-rw-r--r-- | apps/gallery/lib/tiles.php | 2 |
4 files changed, 44 insertions, 3 deletions
diff --git a/apps/gallery/lib/album.php b/apps/gallery/lib/album.php index 39d6d3aded1..701949d4d80 100644 --- a/apps/gallery/lib/album.php +++ b/apps/gallery/lib/album.php @@ -58,7 +58,7 @@ class OC_Gallery_Album { return $stmt->execute($args); } - public static function removeByName($owner, $name) { self::remove($ownmer, $name); } + public static function removeByName($owner, $name) { self::remove($owner, $name); } public static function removeByPath($owner, $path) { self::remove($owner, null, $path); } public static function removeByParentPath($owner, $parent) { self::remove($owner, null, null, $parent); } diff --git a/apps/gallery/lib/managers.php b/apps/gallery/lib/managers.php index b6ade3d1b1e..575d962dbe3 100644 --- a/apps/gallery/lib/managers.php +++ b/apps/gallery/lib/managers.php @@ -29,7 +29,6 @@ class DatabaseManager { $stmt = \OCP\DB::prepare('INSERT INTO *PREFIX*pictures_images_cache (uid_owner, path, width, height) VALUES (?, ?, ?, ?)'); $stmt->execute(array(\OCP\USER::getUser(), $path, $width, $height)); $ret = array('path' => $path, 'width' => $width, 'height' => $height); - unset($image); $dir = dirname($path); $this->cache[$dir][$path] = $ret; return $ret; diff --git a/apps/gallery/lib/share.php b/apps/gallery/lib/share.php new file mode 100644 index 00000000000..6f3db45375f --- /dev/null +++ b/apps/gallery/lib/share.php @@ -0,0 +1,42 @@ +<?php +/** +* ownCloud +* +* @author Michael Gapczynski +* @copyright 2012 Michael Gapczynski mtgap@owncloud.com +* +* This library is free software; you can redistribute it and/or +* modify it under the terms of the GNU AFFERO GENERAL PUBLIC LICENSE +* License as published by the Free Software Foundation; either +* version 3 of the License, or any later version. +* +* This library is distributed in the hope that it will be useful, +* but WITHOUT ANY WARRANTY; without even the implied warranty of +* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +* GNU AFFERO GENERAL PUBLIC LICENSE for more details. +* +* You should have received a copy of the GNU Affero General Public +* License along with this library. If not, see <http://www.gnu.org/licenses/>. +*/ + +class OC_Share_Backend_Photo extends OCP\Share_Backend { + + public $dependsOn = 'file'; + public $supportedFileExtensions = array('jpg', 'png', 'gif'); + + public function getSource($item, $uid) { + return array('item' => 'blah.jpg', 'file' => $item); + } + + public function generateTarget($item, $uid, $exclude = null) { + // TODO Make sure target path doesn't exist already + return $item; + } + + public function formatItems($items, $format, $parameters = null) { + + } + +} + +?>
\ No newline at end of file diff --git a/apps/gallery/lib/tiles.php b/apps/gallery/lib/tiles.php index 754734e609e..e36d26d3191 100644 --- a/apps/gallery/lib/tiles.php +++ b/apps/gallery/lib/tiles.php @@ -33,7 +33,7 @@ class TilesLine { } public function setAvailableSpace($space) { - $available_space = $space; + $this->available_space = $space; } public function getTilesCount() { |