use of com.herewhite.sdk.domain.MemberState in project whiteboard-android by netless-io.
the class PptResourceCacheActivity method shape.
public void shape(MenuItem item) {
logAction();
MemberState memberState = new MemberState();
memberState.setStrokeColor(new int[] { 200, 200, 200 });
// defalut Shape Triangle
// memberState.setCurrentApplianceName(Appliance.SHAPE);
// memberState.setShapeType(ShapeType.Rhombus);
memberState.setStrokeWidth(4);
memberState.setTextSize(10);
mRoom.setMemberState(memberState);
}
use of com.herewhite.sdk.domain.MemberState in project whiteboard-android by netless-io.
the class RoomActivityTest method testSetAndGet_MemberState.
@Test
public void testSetAndGet_MemberState() {
onIdle();
MemberState state = new MemberState();
state.setStrokeColor(new int[] { 99, 99, 99 });
state.setCurrentApplianceName(Appliance.TEXT);
state.setStrokeWidth(10);
state.setTextSize(10);
mActivity.mRoom.setMemberState(state);
mActivity.mRoom.getMemberState(new Promise<MemberState>() {
@Override
public void then(MemberState memberState) {
assertEquals(state.getCurrentApplianceName(), memberState.getCurrentApplianceName());
assertArrayEquals(state.getStrokeColor(), memberState.getStrokeColor());
assertEquals(state.getStrokeWidth(), memberState.getStrokeWidth(), Constants.DOUBLE_DELTA);
assertEquals(state.getTextSize(), memberState.getTextSize(), Constants.DOUBLE_DELTA);
}
@Override
public void catchEx(SDKError t) {
}
});
}
use of com.herewhite.sdk.domain.MemberState in project whiteboard-android by netless-io.
the class RoomActivityTest method testDrawLineNet.
@Test
@Ignore
public void testDrawLineNet() {
onView(withId(R.id.white)).check(matches(isDisplayed()));
MemberState memberState = mActivity.mRoom.getMemberState();
memberState.setStrokeColor(new int[] { 0xEF, 0x3A, 0x48 });
mActivity.mRoom.setMemberState(memberState);
drawVLines();
drawHLines();
}
use of com.herewhite.sdk.domain.MemberState in project whiteboard-android by netless-io.
the class PptResourceCacheActivity method rectangle.
public void rectangle(MenuItem item) {
logAction();
MemberState memberState = new MemberState();
memberState.setStrokeColor(new int[] { 99, 99, 99 });
memberState.setCurrentApplianceName(Appliance.RECTANGLE);
memberState.setStrokeWidth(10);
memberState.setTextSize(10);
mRoom.setMemberState(memberState);
}
use of com.herewhite.sdk.domain.MemberState in project whiteboard-android by netless-io.
the class PptResourceCacheActivity method color.
public void color(MenuItem item) {
logAction();
MemberState memberState = new MemberState();
memberState.setStrokeColor(new int[] { 200, 200, 200 });
memberState.setCurrentApplianceName(Appliance.PENCIL);
memberState.setStrokeWidth(4);
memberState.setTextSize(10);
mRoom.setMemberState(memberState);
}
Aggregations