mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 630595. Backing out f05874a6bac5. r=blassey. a=blocking-fennec
This commit is contained in:
parent
2eb420d816
commit
d987e58396
@ -40,9 +40,6 @@
|
|||||||
#include "android/log.h"
|
#include "android/log.h"
|
||||||
#include "nsString.h"
|
#include "nsString.h"
|
||||||
#include "nsAppShell.h"
|
#include "nsAppShell.h"
|
||||||
#include "nsIPropertyBag2.h"
|
|
||||||
#include "nsIServiceManager.h"
|
|
||||||
#include "nsXULAppAPI.h"
|
|
||||||
|
|
||||||
NS_IMPL_ISUPPORTS1(nsMemoryWatcher, nsITimerCallback)
|
NS_IMPL_ISUPPORTS1(nsMemoryWatcher, nsITimerCallback)
|
||||||
|
|
||||||
@ -76,27 +73,7 @@ nsMemoryWatcher::StartWatching()
|
|||||||
{
|
{
|
||||||
if (mTimer)
|
if (mTimer)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
// Prevent this from running in the child process
|
|
||||||
if (XRE_GetProcessType() != GeckoProcessType_Default)
|
|
||||||
return;
|
|
||||||
|
|
||||||
// Prevent this from running anything but the devices that need it
|
|
||||||
nsCOMPtr<nsIPropertyBag2> sysInfo = do_GetService("@mozilla.org/system-info;1");
|
|
||||||
if (sysInfo) {
|
|
||||||
nsCString deviceType;
|
|
||||||
nsresult rv = sysInfo->GetPropertyAsACString(NS_LITERAL_STRING("device"),
|
|
||||||
deviceType);
|
|
||||||
if (NS_SUCCEEDED(rv)) {
|
|
||||||
if (! deviceType.EqualsLiteral("Nexus S"))
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
__android_log_print(ANDROID_LOG_WARN, "Gecko",
|
|
||||||
"!!!!!!!!! Watching Memory....");
|
|
||||||
|
|
||||||
|
|
||||||
mMemInfoFile = fopen("/proc/meminfo", "r");
|
mMemInfoFile = fopen("/proc/meminfo", "r");
|
||||||
NS_ASSERTION(mMemInfoFile, "Could not open /proc/meminfo for reading.");
|
NS_ASSERTION(mMemInfoFile, "Could not open /proc/meminfo for reading.");
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user