/* * Copyright (c) Linux community. * * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Library General Public * License as published by the Free Software Foundation; either * version 2 of the License, or (at your option) 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 * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public * License along with this library; if not, write to the * Free Software Foundation, Inc., 59 Temple Place - Suite 330, * Boston, MA 02111-1307, USA. */ #include "support.h" gchar *get_data_directory() { // Get data directory // Normally: /usr/share/ // Caller should g_free() this value return g_strdup(DATA_DIR); } gchar *get_package_data_directory() { // Get package data location // Normally: /usr/share/audio-recorder/ // Caller should g_free() this value return g_strdup(PACKAGE_DATA_DIR); } gchar *get_image_directory() { // Get pixmaps directory // Normally: /usr/share/pixmaps/audio-recorder/ // Caller should g_free() this value return g_strdup(PIXMAPS_DIR); } gchar *get_image_path(const gchar *image_name) { // Return path/image_name gchar *path = get_image_directory(); gchar *fname = g_build_filename(path, image_name, NULL); g_free(path); // Caller should g_free() this value return fname; } gchar *get_program_name() { // Program name. // Translators: This is the name of this Audio Recorder program. gchar *name = g_strdup(_("Audio Recorder")); // Caller should g_free() this value. return name; }