]> git.agnieray.net Git - galette.git/blob - galette/lib/Galette/Core/PrintLogo.php
bd3b339f89fb082dee28b31aa26844381b8ea4a4
[galette.git] / galette / lib / Galette / Core / PrintLogo.php
1 <?php
2
3 /* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
4
5 /**
6 * Logo handling - for printing
7 *
8 * PHP version 5
9 *
10 * Copyright © 2009-2014 The Galette Team
11 *
12 * This file is part of Galette (http://galette.tuxfamily.org).
13 *
14 * Galette is free software: you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation, either version 3 of the License, or
17 * (at your option) any later version.
18 *
19 * Galette is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU General Public License for more details.
23 *
24 * You should have received a copy of the GNU General Public License
25 * along with Galette. If not, see <http://www.gnu.org/licenses/>.
26 *
27 * @category Core
28 * @package Galette
29 *
30 * @author Johan Cwiklinski <johan@x-tnd.be>
31 * @copyright 2009-2014 The Galette Team
32 * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version
33 * @version SVN: $Id: print_logo.class.php 546 2009-03-05 06:09:00Z trashy $
34 * @link http://galette.tuxfamily.org
35 * @since Available since 0.7dev - 2009-09-20
36 */
37
38 namespace Galette\Core;
39
40 /**
41 * This class stores a logo for printing that could be different
42 * from the default one.
43 * If no print logo is found, we take the default Logo instead.
44 *
45 * @category Core
46 * @name PrintLogo
47 * @package Galette
48 * @author Johan Cwiklinski <johan@x-tnd.be>
49 * @copyright 2009-2014 The Galette Team
50 * @license http://www.gnu.org/licenses/gpl-3.0.html GPL License 3.0 or (at your option) any later version
51 * @link http://galette.tuxfamily.org
52 * @since Available since 0.7dev - 2009-09-20
53 */
54 class PrintLogo extends Logo
55 {
56 protected $id = 'custom_print_logo';
57 //database wants a member id (integer), not a string.
58 //Will be used to query the correct id
59 protected $db_id = 999999;
60
61 /**
62 * Gets the default picture to show, anyways
63 *
64 * @see Logo::getDefaultPicture()
65 *
66 * @return void
67 */
68 protected function getDefaultPicture()
69 {
70 //if we are here, we want to serve default logo
71 $pic = new Logo();
72 $this->file_path = $pic->getPath();
73 $this->format = $pic->getFormat();
74 $this->mime = $pic->getMime();
75 //anyways, we have no custom print logo
76 $this->custom = false;
77 }
78 }