summaryrefslogtreecommitdiff
path: root/libcheese/totem-aspect-frame.h
blob: f0e28794b1ef51be99990c41dae96e438c441623 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83

/* -*- mode: C; c-file-style: "gnu"; indent-tabs-mode: nil; -*- */
/*
 * mx-aspect-frame.h: A container that respect the aspect ratio of its child
 *
 * Copyright 2010, 2011 Intel Corporation.
 *
 * This program is free software; you can redistribute it and/or modify it
 * under the terms and conditions of the GNU Lesser General Public License,
 * version 2.1, as published by the Free Software Foundation.
 *
 * This program is distributed in the hope it will be useful, but WITHOUT ANY
 * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
 * FOR A PARTICULAR PURPOSE.  See the GNU Lesser General Public License for
 * more details.
 *
 * You should have received a copy of the GNU Lesser General Public License
 * along with this program; if not, write to the Free Software Foundation,
 * Inc., 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
 * Boston, MA 02111-1307, USA.
 *
 */

#ifndef __TOTEM_ASPECT_FRAME_H__
#define __TOTEM_ASPECT_FRAME_H__

#include <glib-object.h>
#include <clutter/clutter.h>

G_BEGIN_DECLS

#define TOTEM_TYPE_ASPECT_FRAME totem_aspect_frame_get_type()

#define TOTEM_ASPECT_FRAME(obj) \
  (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
  TOTEM_TYPE_ASPECT_FRAME, TotemAspectFrame))

#define TOTEM_ASPECT_FRAME_CLASS(klass) \
  (G_TYPE_CHECK_CLASS_CAST ((klass), \
  TOTEM_TYPE_ASPECT_FRAME, TotemAspectFrameClass))

#define TOTEM_IS_ASPECT_FRAME(obj) \
  (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
  TOTEM_TYPE_ASPECT_FRAME))

#define TOTEM_IS_ASPECT_FRAME_CLASS(klass) \
  (G_TYPE_CHECK_CLASS_TYPE ((klass), \
  TOTEM_TYPE_ASPECT_FRAME))

#define TOTEM_ASPECT_FRAME_GET_CLASS(obj) \
  (G_TYPE_INSTANCE_GET_CLASS ((obj), \
  TOTEM_TYPE_ASPECT_FRAME, TotemAspectFrameClass))

typedef struct _TotemAspectFrame TotemAspectFrame;
typedef struct _TotemAspectFrameClass TotemAspectFrameClass;
typedef struct _TotemAspectFramePrivate TotemAspectFramePrivate;

struct _TotemAspectFrame
{
  ClutterActor parent;

  TotemAspectFramePrivate *priv;
};

struct _TotemAspectFrameClass
{
  ClutterActorClass parent_class;
};

GType           totem_aspect_frame_get_type    (void) G_GNUC_CONST;

ClutterActor *  totem_aspect_frame_new         (void);

void            totem_aspect_frame_set_child   (TotemAspectFrame *frame,
						ClutterActor     *child);

void            totem_aspect_frame_set_expand  (TotemAspectFrame *frame,
                                                gboolean          expand);
gboolean        totem_aspect_frame_get_expand  (TotemAspectFrame *frame);

G_END_DECLS

#endif /* __TOTEM_ASPECT_FRAME_H__ */