FormLayout.java 1.55 KB
/*
 * Decompiled with CFR 0_118.
 */
package com.adobe.xfa.layout;

import com.adobe.xfa.AppModel;
import com.adobe.xfa.font.FontService;
import com.adobe.xfa.layout.Layout;
import com.adobe.xfa.layout.LayoutDriver;
import com.adobe.xfa.layout.LayoutEnv;
import com.adobe.xfa.service.Service;
import com.adobe.xfa.service.href.HrefService;

public class FormLayout
extends Layout {
    private LayoutDriver moLayoutDriver;
    private boolean mbNeedSecondPass;
    private boolean mbSecondPass;

    public FormLayout(AppModel oAppModel) {
        super(oAppModel);
        assert (oAppModel != null);
        this.mbNeedSecondPass = false;
        this.mbSecondPass = false;
    }

    public FormLayout(FontService oFontService, Service oImageService, HrefService oHrefService, AppModel oAppModel) {
        super(oAppModel);
        assert (oAppModel != null);
        assert (oFontService != null);
        assert (oImageService != null);
        assert (oHrefService != null);
        this.mbNeedSecondPass = false;
        this.mbSecondPass = false;
        this.moLayoutDriver = new LayoutDriver();
        LayoutEnv oEnv = new LayoutEnv(oFontService, oImageService, oHrefService, this.moLayoutDriver);
        super.setLayoutEnv(oEnv);
    }

    @Override
    public void layout(boolean bFullLayout) {
    }

    public boolean needsSecondPass() {
        return this.mbNeedSecondPass;
    }

    public void setNeedsSecondPass() {
        this.mbNeedSecondPass = !this.mbSecondPass;
    }

    protected LayoutDriver getLayoutDriver() {
        return this.moLayoutDriver;
    }
}