aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMax Horn2003-08-06 00:28:00 +0000
committerMax Horn2003-08-06 00:28:00 +0000
commit0c3c6094420787c4f4cbd86a0ebe41c2ade838ee (patch)
tree2543cf60215114d7d0eb05d418486149d43b18cc
parent77d3e9333be2570c808aa8d6fed71bca6fd3b9df (diff)
downloadscummvm-rg350-0c3c6094420787c4f4cbd86a0ebe41c2ade838ee.tar.gz
scummvm-rg350-0c3c6094420787c4f4cbd86a0ebe41c2ade838ee.tar.bz2
scummvm-rg350-0c3c6094420787c4f4cbd86a0ebe41c2ade838ee.zip
get rid of some g_system usage
svn-id: r9529
-rw-r--r--gui/PopUpWidget.cpp4
-rw-r--r--sky/music/adlibmusic.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/gui/PopUpWidget.cpp b/gui/PopUpWidget.cpp
index dfd168bd47..96dc9f1581 100644
--- a/gui/PopUpWidget.cpp
+++ b/gui/PopUpWidget.cpp
@@ -104,7 +104,7 @@ PopUpDialog::PopUpDialog(PopUpWidget *boss, int clickX, int clickY)
_clickY = clickY - _y;
// Time the popup was opened
- _openTime = g_system->get_msecs();
+ _openTime = _gui->get_time();
}
void PopUpDialog::drawDialog() {
@@ -127,7 +127,7 @@ void PopUpDialog::handleMouseUp(int x, int y, int button, int clickCount) {
// Mouse was released. If it wasn't moved much since the original mouse down,
// let the popup stay open. If it did move, assume the user made his selection.
int dist = (_clickX - x) * (_clickX - x) + (_clickY - y) * (_clickY - y);
- if (dist > 3 * 3 || g_system->get_msecs() - _openTime > 300) {
+ if (dist > 3 * 3 || _gui->get_time() - _openTime > 300) {
setResult(_selection);
close();
}
diff --git a/sky/music/adlibmusic.cpp b/sky/music/adlibmusic.cpp
index 836fe24806..7aaf6e8c0e 100644
--- a/sky/music/adlibmusic.cpp
+++ b/sky/music/adlibmusic.cpp
@@ -32,12 +32,12 @@ SkyAdlibMusic::SkyAdlibMusic(SoundMixer *pMixer, SkyDisk *pSkyDisk, OSystem *sys
_driverFileBase = 60202;
_mixer = pMixer;
- _sampleRate = g_system->property(OSystem::PROP_GET_SAMPLE_RATE, 0);
+ _sampleRate = pMixer->getOutputRate();
int env_bits = g_system->property(OSystem::PROP_GET_FMOPL_ENV_BITS, NULL);
int eg_ent = g_system->property(OSystem::PROP_GET_FMOPL_EG_ENT, NULL);
OPLBuildTables((env_bits ? env_bits : FMOPL_ENV_BITS_HQ), (eg_ent ? eg_ent : FMOPL_EG_ENT_HQ));
- _opl = OPLCreate(OPL_TYPE_YM3812, 3579545, g_system->property(OSystem::PROP_GET_SAMPLE_RATE, 0));
+ _opl = OPLCreate(OPL_TYPE_YM3812, 3579545, _sampleRate);
_mixer->setupPremix(this, passMixerFunc);
}