Skip to content
Snippets Groups Projects
Commit c6ab5f05 authored by yanmorin's avatar yanmorin
Browse files

*** empty log message ***

parent 8c859fd7
No related branches found
No related tags found
No related merge requests found
SUBDIRS = utilspp stund src ringtones
SUBDIRS = utilspp stund src ringtones tools
......@@ -90,23 +90,6 @@ SFLPHONE_LIBS="$SFLPHONE_LIBS $libexosip2_LIBS"
dnl AC_SUBST(LIBQT)
AC_MSG_CHECKING([whether to enable the new gui])
AC_ARG_ENABLE(newgui,
[ --enable-newgui Enable new gui code [default=no]],
[
AC_MSG_RESULT(yes)
newgui="yes"
],
[
AC_MSG_RESULT(no)
newgui="no"
]
)
AM_CONDITIONAL(NEWGUI_CODE, test x$newgui = xyes)
if test $ac_cv_header_portaudio_h = no; then
AC_MSG_ERROR([*** missing portaudio.h. You need a working PortAudio installation. See http://www.portaudio.com])
fi
......@@ -181,4 +164,5 @@ utilspp/functor/Makefile \
utilspp/singleton/Makefile \
stund/Makefile \
ringtones/Makefile \
tools/Makefile \
)
......@@ -205,6 +205,15 @@ ConfigTree::populateFromFile(const std::string& fileName) {
file.close();
return 2;
}
// get length of file:
file.seekg (0, std::ios::end);
int length = file.tellg();
file.seekg (0, std::ios::beg);
if ( length == 0 ) {
file.close();
return 2; // should load config
}
std::string line;
std::string section("");
......
......@@ -113,7 +113,6 @@ ManagerImpl::~ManagerImpl (void)
void
ManagerImpl::init (void)
{
initZeroconf();
initVolume();
if (_exist == 0) {
......@@ -159,6 +158,7 @@ ManagerImpl::init (void)
}
}
initZeroconf();
}
void ManagerImpl::terminate()
......@@ -751,6 +751,8 @@ ManagerImpl::displayErrorText (CALLID id, const std::string& message)
{
if(_gui) {
_gui->displayErrorText(id, message);
} else {
std::cerr << message << std::endl;
}
}
......@@ -1114,7 +1116,7 @@ ManagerImpl::selectAudioDriver (void)
_audiodriverPA = new AudioLayer(*this);
int noDevice = getConfigInt(AUDIO, DRIVER_NAME);
int nbDevice = portaudio::System::instance().deviceCount();
if (nbDevice == 0 ) {
if (nbDevice == 0) {
throw std::runtime_error("Portaudio detect no sound card.");
} else if (noDevice >= nbDevice) {
_debug("Portaudio auto-select device #0 because device #%d is not found\n", noDevice);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment