Exemplo n.º 1
0
		void showResource(ResourceItem item)
		{
			if(item == null) {
				showView(null);
				return;
			}
			if (item.ResourceValue is Icon) {
				IconView iv = new IconView(item);
				showView(iv);
			} else if(item.ResourceValue is Bitmap) {
				BitmapView bv = new BitmapView(item);
				showView(bv);
			} else if(item.ResourceValue is Cursor) {
				CursorView cv = new CursorView(item);
				showView(cv);
			} else if(item.ResourceValue is string) {
				TextView tv = new TextView(item);
				showView(tv);
			} else if(item.ResourceValue is byte[]) {
				BinaryView bv = new BinaryView(item);
				showView(bv);
			} else if(item.ResourceValue is bool) {
				BooleanView bv = new BooleanView(item);
				showView(bv);
			} else {
				showView(null);
			}
		}