wassim
wassim
Reputation Top 1%
Wassim ALI
14 Snippets  (56th place)
Published
0 Channels
Created
1 Channel
Following
Jul 8, 2018
Last Visit
Jan 13, 2013
Registered
978 points  (45th place)
Reputation
Top 10% Publisher
Junior Code Generator
Serious Code Generator
Senior Code Generator
Master Code Generator
Junior Publisher
Serious Publisher
Junior Popular Coder
Serious Popular Coder
Senior Popular Coder
Junior Autobiographer
Serious Autobiographer
Senior Autobiographer
Master Autobiographer
Senior Famous Coder
Junior Wise Coder

Recent Snippets See all snippets by wassim

public by wassim created Jan 19, 2015  2080  1  6  0

SHOW IMAGE IN ANDROID MAP MARKER

How to show image in android map marker
imageLoader = ImageLoader.getInstance();
        options = new DisplayImageOptions.Builder()
		.showImageOnLoading(R.drawable.ic_launcher)
		.showImageForEmptyUri(R.drawable.ic_launcher)
		.showImageOnFail(R.drawable.ic_launcher)
		.cacheInMemory(true)
		.cacheOnDisk(true)
		.considerExifParams(true)
		.displayer(new RoundedBitmapDisplayer(20))
		.build();
		
        imageLoader.init(ImageLoaderConfiguration.createDefault(CustomMapMarker.this));
    
        imageLoader.displayImage(url, image_marker, options,
				new SimpleImageLoadingListener() {
					@Override
					public void onLoadingComplete(String imageUri,
							View view, Bitmap loadedImage) {
						super.onLoadingComplete(imageUri, view,
								loadedImage);
						getInfoContents(customMarker);
					}
				});

public View getInfoContents(Marker marker) {

		if (marker != null
				&& marker.isInfoWindowShown()) {
			marker.hideInfoWindow();
			marker.showInfoWindow();
		}
		return null;
	}
;

public by wassim created Jan 19, 2015  2518  7  5  0

ANDORID IMAGE LOADER PROBLEM (imageloader must be init with configuration before using)

ANDROID: init IMAGE LOADER ANDROID EXCEPTION (imageloader must be init with configuration before using)
imageLoader.init(ImageLoaderConfiguration.createDefault(CustomMapMarker.this));
;

public by wassim created Nov 24, 2014  3030  2  5  1

How to detect device is Android phone or Android tablet?

How to detect device is Android phone or Android tablet?
if((getResources().getConfiguration().screenLayout & Configuration.SCREENLAYOUT_SIZE_MASK)
                    >= Configuration.SCREENLAYOUT_SIZE_LARGE)
        
    	  type="Tablet";
      else 
    	  type= "Smartphone";
    	  
        Toast.makeText(MainActivity.this,type, Toast.LENGTH_LONG).show();
;

public by wassim created Oct 31, 2014  2847  1  5  0

iOS display Alert using UIAlertView

how to display alert in ios example
 
 
UIAlertView *message = [[UIAlertView alloc] initWithTitle:@"Hello World!"
                                                     message:@"This is your first UIAlertview message."
                                                    delegate:nil
                                           cancelButtonTitle:@"OK"
                                           otherButtonTitles:nil];
                                            
                                            [message show];
;

public by wassim created Oct 30, 2014  2039  0  5  4

IOS display web page

how to display web page in ios example
 
 
NSString *urlAddress = @"http://www.google.com";
       NSURL *url = [NSURL URLWithString:urlAddress];
       NSURLRequest *requestObj = [NSURLRequest requestWithURL:url];
       [webDisplay loadRequest:requestObj];
       [super viewDidLoad];
;