예제 #1
0
void WebPageCreationParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << viewSize;
    encoder << isActive;
    encoder << isFocused;
    encoder << isVisible;
    encoder << isInWindow;

    encoder << store;
    encoder.encodeEnum(drawingAreaType);
    encoder << pageGroupData;
    encoder << drawsBackground;
    encoder << drawsTransparentBackground;
    encoder << underlayColor;
    encoder << areMemoryCacheClientCallsEnabled;
    encoder << useFixedLayout;
    encoder << fixedLayoutSize;
    encoder.encodeEnum(paginationMode);
    encoder << paginationBehavesLikeColumns;
    encoder << pageLength;
    encoder << gapBetweenPages;
    encoder << userAgent;
    encoder << sessionState;
    encoder << highestUsedBackForwardItemID;
    encoder << canRunBeforeUnloadConfirmPanel;
    encoder << canRunModal;
    encoder << deviceScaleFactor;
    encoder << mediaVolume;
    encoder << mayStartMediaWhenInWindow;

#if PLATFORM(MAC)
    encoder.encodeEnum(layerHostingMode);
    encoder << colorSpace;
#endif
}
예제 #2
0
void WebContextMenuItemData::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder.encodeEnum(m_type);
    encoder.encodeEnum(m_action);
    encoder << m_title;
    encoder << m_checked;
    encoder << m_enabled;
    encoder << m_submenu;
}
예제 #3
0
void NetworkResourceLoadParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder.encode(m_request);

    encoder.encode(static_cast<bool>(m_request.httpBody()));
    if (m_request.httpBody()) {
        EncoderAdapter httpBodyEncoderAdapter;
        m_request.httpBody()->encode(httpBodyEncoderAdapter);
        encoder.encode(httpBodyEncoderAdapter.dataReference());
    }

    encoder.encodeEnum(m_priority);
    encoder.encodeEnum(m_contentSniffingPolicy);
    encoder.encodeEnum(m_allowStoredCredentials);
    encoder.encode(m_inPrivateBrowsingMode);
}
void NetworkResourceLoadParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << m_identifier;
    encoder << m_webPageID;
    encoder << m_webFrameID;
    encoder << m_request;

    encoder << static_cast<bool>(m_request.httpBody());
    if (m_request.httpBody()) {
        EncoderAdapter httpBodyEncoderAdapter;
        m_request.httpBody()->encode(httpBodyEncoderAdapter);
        encoder << httpBodyEncoderAdapter.dataReference();

        const Vector<FormDataElement>& elements = m_request.httpBody()->elements();
        size_t fileCount = 0;
        for (size_t i = 0, count = elements.size(); i < count; ++i) {
            if (elements[i].m_type == FormDataElement::encodedFile)
                ++fileCount;
        }

        SandboxExtension::HandleArray requestBodySandboxExtensions;
        requestBodySandboxExtensions.allocate(fileCount);
        size_t extensionIndex = 0;
        for (size_t i = 0, count = elements.size(); i < count; ++i) {
            const FormDataElement& element = elements[i];
            if (element.m_type == FormDataElement::encodedFile) {
                const String& path = element.m_shouldGenerateFile ? element.m_generatedFilename : element.m_filename;
                SandboxExtension::createHandle(path, SandboxExtension::ReadOnly, requestBodySandboxExtensions[extensionIndex++]);
            }
        }
        encoder << requestBodySandboxExtensions;
    }

    if (m_request.url().isLocalFile()) {
        SandboxExtension::Handle requestSandboxExtension;
        SandboxExtension::createHandle(m_request.url().fileSystemPath(), SandboxExtension::ReadOnly, requestSandboxExtension);
        encoder << requestSandboxExtension;
    }

    encoder.encodeEnum(m_priority);
    encoder.encodeEnum(m_contentSniffingPolicy);
    encoder.encodeEnum(m_allowStoredCredentials);
    encoder << m_inPrivateBrowsingMode;
    encoder << m_shouldClearReferrerOnHTTPSToHTTPRedirect;
}
void SecItemRequestData::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder.encodeEnum(m_type);

    CoreIPC::encode(encoder, m_queryDictionary.get());

    encoder << static_cast<bool>(m_attributesToMatch);
    if (m_attributesToMatch)
        CoreIPC::encode(encoder, m_attributesToMatch.get());
}
예제 #6
0
void Plugin::Parameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << url.string();
    encoder << names;
    encoder << values;
    encoder << mimeType;
    encoder << isFullFramePlugin;
    encoder << shouldUseManualLoader;
#if PLATFORM(MAC)
    encoder.encodeEnum(layerHostingMode);
#endif
}
예제 #7
0
void PrintInfo::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << pageSetupScaleFactor;
    encoder << availablePaperWidth;
    encoder << availablePaperHeight;

#if PLATFORM(GTK)
    CoreIPC::encode(encoder, printSettings.get());
    CoreIPC::encode(encoder, pageSetup.get());
    encoder.encodeEnum(printMode);
#endif
}
예제 #8
0
void WebPageCreationParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder.encode(viewSize);
    encoder.encode(isActive);
    encoder.encode(isFocused);
    encoder.encode(isVisible);
    encoder.encode(isInWindow);

    encoder.encode(store);
    encoder.encodeEnum(drawingAreaType);
    encoder.encode(pageGroupData);
    encoder.encode(drawsBackground);
    encoder.encode(drawsTransparentBackground);
    encoder.encode(areMemoryCacheClientCallsEnabled);
    encoder.encode(useFixedLayout);
    encoder.encode(fixedLayoutSize);
    encoder.encodeEnum(paginationMode);
    encoder.encode(paginationBehavesLikeColumns);
    encoder.encode(pageLength);
    encoder.encode(gapBetweenPages);
    encoder.encode(userAgent);
    encoder.encode(sessionState);
    encoder.encode(highestUsedBackForwardItemID);
    encoder.encode(canRunBeforeUnloadConfirmPanel);
    encoder.encode(canRunModal);
    encoder.encode(deviceScaleFactor);
    encoder.encode(mediaVolume);

#if PLATFORM(MAC)
    encoder.encode(isSmartInsertDeleteEnabled);
    encoder.encodeEnum(layerHostingMode);
    encoder.encode(colorSpace);
#endif

#if PLATFORM(WIN)
    encoder.encode(reinterpret_cast<uint64_t>(nativeWindow));
#endif
}
void NetworkProcessCreationParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << privateBrowsingEnabled;
    encoder.encodeEnum(cacheModel);
    encoder << diskCacheDirectory;
    encoder << diskCacheDirectoryExtensionHandle;
    encoder << shouldUseTestingNetworkSession;
#if PLATFORM(MAC)
    encoder << parentProcessName;
    encoder << uiProcessBundleIdentifier;
    encoder << nsURLCacheMemoryCapacity;
    encoder << nsURLCacheDiskCapacity;
#if ENABLE(CUSTOM_PROTOCOLS)
    encoder << urlSchemesRegisteredForCustomProtocols;
#endif
    encoder << httpProxy;
    encoder << httpsProxy;
#endif
}
void WebProcessCreationParameters::encode(CoreIPC::ArgumentEncoder& encoder) const
{
    encoder << injectedBundlePath;
    encoder << injectedBundlePathExtensionHandle;
    encoder << applicationCacheDirectory;
    encoder << applicationCacheDirectoryExtensionHandle;
    encoder << databaseDirectory;
    encoder << databaseDirectoryExtensionHandle;
    encoder << localStorageDirectory;
    encoder << localStorageDirectoryExtensionHandle;
    encoder << diskCacheDirectory;
    encoder << diskCacheDirectoryExtensionHandle;
    encoder << cookieStorageDirectory;
    encoder << cookieStorageDirectoryExtensionHandle;
    encoder << shouldUseTestingNetworkSession;
    encoder << urlSchemesRegistererdAsEmptyDocument;
    encoder << urlSchemesRegisteredAsSecure;
    encoder << urlSchemesForWhichDomainRelaxationIsForbidden;
    encoder << urlSchemesRegisteredAsLocal;
    encoder << urlSchemesRegisteredAsNoAccess;
    encoder << urlSchemesRegisteredAsDisplayIsolated;
    encoder << urlSchemesRegisteredAsCORSEnabled;
#if ENABLE(CUSTOM_PROTOCOLS)
    encoder << urlSchemesRegisteredForCustomProtocols;
#endif
#if USE(SOUP)
    encoder << urlSchemesRegistered;
    encoder << cookiePersistentStoragePath;
    encoder << cookiePersistentStorageType;
    encoder.encodeEnum(cookieAcceptPolicy);
    encoder << ignoreTLSErrors;
#endif
    encoder.encodeEnum(cacheModel);
    encoder << shouldTrackVisitedLinks;
    encoder << shouldAlwaysUseComplexTextCodePath;
    encoder << shouldUseFontSmoothing;
    encoder << iconDatabaseEnabled;
    encoder << terminationTimeout;
    encoder << languages;
    encoder << textCheckerState;
    encoder << fullKeyboardAccessEnabled;
    encoder << defaultRequestTimeoutInterval;
#if PLATFORM(MAC) || USE(CFNETWORK)
    encoder << uiProcessBundleIdentifier;
#endif
#if PLATFORM(MAC)
    encoder << presenterApplicationPid;
    encoder << accessibilityEnhancedUserInterfaceEnabled;
    encoder << nsURLCacheMemoryCapacity;
    encoder << nsURLCacheDiskCapacity;
    encoder << acceleratedCompositingPort;
    encoder << uiProcessBundleResourcePath;
    encoder << uiProcessBundleResourcePathExtensionHandle;
    encoder << shouldForceScreenFontSubstitution;
    encoder << shouldEnableKerningAndLigaturesByDefault;
#endif

#if ENABLE(NOTIFICATIONS) || ENABLE(LEGACY_NOTIFICATIONS)
    encoder << notificationPermissions;
#endif

#if ENABLE(NETWORK_PROCESS)
    encoder << usesNetworkProcess;
#endif

    encoder << plugInAutoStartOriginHashes;
    encoder << plugInAutoStartOrigins;
}