本文整理汇总了Java中org.w3c.dom.smil.SMILRegionElement类的典型用法代码示例。如果您正苦于以下问题:Java SMILRegionElement类的具体用法?Java SMILRegionElement怎么用?Java SMILRegionElement使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
SMILRegionElement类属于org.w3c.dom.smil包,在下文中一共展示了SMILRegionElement类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。
示例1: getRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
private static SMILRegionElement getRegion(SMILDocument document, PduPart part) {
if (PartParser.isAudio(part)) return null;
SMILRegionElement region = (SMILRegionElement) document.createElement("region");
if (PartParser.isText(part)) {
region.setId("Text");
region.setTop(SmilUtil.ROOT_HEIGHT);
region.setHeight(50);
} else {
region.setId("Image");
region.setTop(0);
region.setHeight(SmilUtil.ROOT_HEIGHT);
}
region.setLeft(0);
region.setWidth(SmilUtil.ROOT_WIDTH);
region.setFit("meet");
return region;
}
开发者ID:XecureIT,项目名称:PeSanKita-android,代码行数:19,代码来源:SmilUtil.java
示例2: createSmilDocument
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
private static SMILDocument createSmilDocument(PduBody body) {
Log.w(TAG, "Creating SMIL document from PduBody.");
SMILDocument document = new SmilDocumentImpl();
SMILElement smilElement = (SMILElement) document.createElement("smil");
document.appendChild(smilElement);
SMILElement headElement = (SMILElement) document.createElement("head");
smilElement.appendChild(headElement);
SMILLayoutElement layoutElement = (SMILLayoutElement) document.createElement("layout");
headElement.appendChild(layoutElement);
SMILRootLayoutElement rootLayoutElement = (SMILRootLayoutElement) document.createElement("root-layout");
rootLayoutElement.setWidth(ROOT_WIDTH);
rootLayoutElement.setHeight(ROOT_HEIGHT);
layoutElement.appendChild(rootLayoutElement);
SMILElement bodyElement = (SMILElement) document.createElement("body");
smilElement.appendChild(bodyElement);
SMILParElement par = (SMILParElement) document.createElement("par");
bodyElement.appendChild(par);
for (int i=0; i<body.getPartsNum(); i++) {
PduPart part = body.getPart(i);
SMILRegionElement regionElement = getRegion(document, part);
SMILMediaElement mediaElement = getMediaElement(document, part);
if (regionElement != null) {
((SMILRegionMediaElement)mediaElement).setRegion(regionElement);
layoutElement.appendChild(regionElement);
}
par.appendChild(mediaElement);
}
return document;
}
开发者ID:XecureIT,项目名称:PeSanKita-android,代码行数:40,代码来源:SmilUtil.java
示例3: getSmilRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
@Override
public SMILRegionElement getSmilRegion(SMILDocument document) {
SMILRegionElement region = (SMILRegionElement) document.createElement("region");
region.setId("Image");
region.setLeft(0);
region.setTop(0);
region.setWidth(SmilUtil.ROOT_WIDTH);
region.setHeight(SmilUtil.ROOT_HEIGHT);
region.setFit("meet");
return region;
}
开发者ID:redcracker,项目名称:TextSecure,代码行数:12,代码来源:VideoSlide.java
示例4: getSmilRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
@Override
public SMILRegionElement getSmilRegion(SMILDocument document) {
SMILRegionElement region = (SMILRegionElement) document.createElement("region");
region.setId("Text");
region.setLeft(0);
region.setTop(SmilUtil.ROOT_HEIGHT);
region.setWidth(SmilUtil.ROOT_WIDTH);
region.setHeight(50);
region.setFit("meet");
return region;
}
开发者ID:redcracker,项目名称:TextSecure,代码行数:12,代码来源:TextSlide.java
示例5: createSmilDocument
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
public static SMILDocument createSmilDocument(SlideDeck deck) {
Log.w(TAG, "Creating SMIL document from SlideDeck.");
SMILDocument document = new SmilDocumentImpl();
SMILElement smilElement = (SMILElement) document.createElement("smil");
document.appendChild(smilElement);
SMILElement headElement = (SMILElement) document.createElement("head");
smilElement.appendChild(headElement);
SMILLayoutElement layoutElement = (SMILLayoutElement) document.createElement("layout");
headElement.appendChild(layoutElement);
SMILRootLayoutElement rootLayoutElement = (SMILRootLayoutElement) document.createElement("root-layout");
rootLayoutElement.setWidth(ROOT_WIDTH);
rootLayoutElement.setHeight(ROOT_HEIGHT);
layoutElement.appendChild(rootLayoutElement);
SMILElement bodyElement = (SMILElement) document.createElement("body");
smilElement.appendChild(bodyElement);
SMILParElement par = (SMILParElement) document.createElement("par");
bodyElement.appendChild(par);
for (Slide slide : deck.getSlides()) {
SMILRegionElement regionElement = slide.getSmilRegion(document);
SMILMediaElement mediaElement = slide.getMediaElement(document);
if (regionElement != null) {
((SMILRegionMediaElement)mediaElement).setRegion(regionElement);
layoutElement.appendChild(regionElement);
}
par.appendChild(mediaElement);
}
return document;
}
开发者ID:redcracker,项目名称:TextSecure,代码行数:39,代码来源:SmilUtil.java
示例6: findRegionElementById
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
private static SMILRegionElement findRegionElementById(
ArrayList<SMILRegionElement> smilRegions, String rId) {
for (SMILRegionElement smilRegion : smilRegions) {
if (smilRegion.getId().equals(rId)) {
return smilRegion;
}
}
return null;
}
开发者ID:moezbhatti,项目名称:qksms,代码行数:10,代码来源:SmilHelper.java
示例7: setRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
private static boolean setRegion(SMILRegionMediaElement srme,
ArrayList<SMILRegionElement> smilRegions,
SMILLayoutElement smilLayout,
String regionId,
boolean regionPresentInLayout) {
SMILRegionElement smilRegion = findRegionElementById(smilRegions, regionId);
if (!regionPresentInLayout && smilRegion != null) {
srme.setRegion(smilRegion);
smilLayout.appendChild(smilRegion);
return true;
}
return false;
}
开发者ID:moezbhatti,项目名称:qksms,代码行数:14,代码来源:SmilHelper.java
示例8: getSmilRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
@Override
public SMILRegionElement getSmilRegion(SMILDocument document) {
SMILRegionElement region = (SMILRegionElement) document.createElement("region");
region.setId("Image");
region.setLeft(0);
region.setTop(0);
region.setWidth(SmilUtil.ROOT_WIDTH);
region.setHeight(SmilUtil.ROOT_HEIGHT);
region.setFit("meet");
return region;
}
开发者ID:Securecom,项目名称:Securecom-Messaging,代码行数:12,代码来源:OtherSlide.java
示例9: setRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
public void setRegion(SMILRegionElement region) {
this.setAttribute("region", region.getId());
mRegion = region;
}
开发者ID:XecureIT,项目名称:PeSanKita-android,代码行数:5,代码来源:SmilRegionMediaElementImpl.java
示例10: getSmilRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
@Override
public SMILRegionElement getSmilRegion(SMILDocument document) {
return null;
}
开发者ID:redcracker,项目名称:TextSecure,代码行数:5,代码来源:AudioSlide.java
示例11: getSmilRegion
import org.w3c.dom.smil.SMILRegionElement; //导入依赖的package包/类
public abstract SMILRegionElement getSmilRegion(SMILDocument document);
开发者ID:redcracker,项目名称:TextSecure,代码行数:2,代码来源:Slide.java
注:本文中的org.w3c.dom.smil.SMILRegionElement类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论