buttons not showing on tablerow
So i decided to crete my layout dinamycally, cuz i feel more in control of them as i can do anything with in code rather than having the layout, inflate, etc, etc. I come from developing first with Symbian, then Blackberry and even though having an drag and drop layout creation interface is rather cool, i feel more at home with this. though i'll still use some D&D layouts

Well, thing is, i have this layout with the spinner, some buttons, and i want them to be in a row style, so obviously I set them in a table row. Here's the code

    public FormaLibrosDisponibles(SisLec _sisLec)
    	{
    		super(_sisLec);
    		sisLec = _sisLec;
    		disenio = new LinearLayout(sisLec);
    		disenio.setOrientation(LinearLayout.VERTICAL);
    		addView(disenio);
    		selecClk = new OnClickListener() 
    		{			
    			public void onClick(View v) 
    			{			
    				seleccionarBtnClick(v);
    			}
    		};
    		cancelarClk = new OnClickListener()
    		{			
    			public void onClick(View v) 
    			{
    				cancelarBtnClick(v);
    			}
    		};		
    		selecBtn = new Button(sisLec);
    		selecBtn.setText("Descargar Libro");
    		selecBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
    		selecBtn.setOnClickListener(selecClk);
    		cancelarBtn = new Button(sisLec);
    		cancelarBtn.setText("Cancelar");
    		cancelarBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
    		cancelarBtn.setOnClickListener(cancelarClk);
    		lineaTabla = new TableRow(sisLec);
    		lineaTabla.addView(selecBtn);
    		lineaTabla.addView(cancelarBtn);
    		lineaTabla.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
    		librosDisponibles = new Spinner(sisLec);
    		disponiblestxtVw = new TextView(sisLec);
    		disponiblestxtVw.setText("Libros Disponibles");
    		disenio.addView(disponiblestxtVw);
    		disenio.addView(librosDisponibles);
    		disenio.addView(lineaTabla);
    	}

But when it fires up, there's no buttons shown, and if i take out the layout params of either button, lets say i do this

    selecBtn = new Button(sisLec);
        		selecBtn.setText("Descargar Libro");
        		//selecBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
        		selecBtn.setOnClickListener(selecClk);
        		cancelarBtn = new Button(sisLec);
        		cancelarBtn.setText("Cancelar");
        		cancelarBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
        		cancelarBtn.setOnClickListener(cancelarClk);

Only cancelarBtn will be shown, and will take all the space. What am i doing wrong here?
buttons not showing on tablerow
===

So i decided to crete my layout dinamycally, cuz i feel more in control of them as i can do anything with in code rather than having the layout, inflate, etc, etc. I come from developing first with Symbian, then Blackberry and even though having an drag and drop layout creation interface is rather cool, i feel more at home with this. though i'll still use some D&D layouts

Well, thing is, i have this layout with the spinner, some buttons, and i want them to be in a row style, so obviously I set them in a table row. Here's the code

    public FormaLibrosDisponibles(SisLec _sisLec)
    	{
    		super(_sisLec);
    		sisLec = _sisLec;
    		disenio = new LinearLayout(sisLec);
    		disenio.setOrientation(LinearLayout.VERTICAL);
    		addView(disenio);
    		selecClk = new OnClickListener() 
    		{			
    			public void onClick(View v) 
    			{			
    				seleccionarBtnClick(v);
    			}
    		};
    		cancelarClk = new OnClickListener()
    		{			
    			public void onClick(View v) 
    			{
    				cancelarBtnClick(v);
    			}
    		};		
    		selecBtn = new Button(sisLec);
    		selecBtn.setText("Descargar Libro");
    		selecBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
    		selecBtn.setOnClickListener(selecClk);
    		cancelarBtn = new Button(sisLec);
    		cancelarBtn.setText("Cancelar");
    		cancelarBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
    		cancelarBtn.setOnClickListener(cancelarClk);
    		lineaTabla = new TableRow(sisLec);
    		lineaTabla.addView(selecBtn);
    		lineaTabla.addView(cancelarBtn);
    		lineaTabla.setLayoutParams(new LayoutParams(LayoutParams.FILL_PARENT, LayoutParams.WRAP_CONTENT));
    		librosDisponibles = new Spinner(sisLec);
    		disponiblestxtVw = new TextView(sisLec);
    		disponiblestxtVw.setText("Libros Disponibles");
    		disenio.addView(disponiblestxtVw);
    		disenio.addView(librosDisponibles);
    		disenio.addView(lineaTabla);
    	}

But when it fires up, there's no buttons shown, and if i take out the layout params of either button, lets say i do this

    selecBtn = new Button(sisLec);
        		selecBtn.setText("Descargar Libro");
        		//selecBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
        		selecBtn.setOnClickListener(selecClk);
        		cancelarBtn = new Button(sisLec);
        		cancelarBtn.setText("Cancelar");
        		cancelarBtn.setLayoutParams(new LayoutParams(LayoutParams.WRAP_CONTENT, LayoutParams.WRAP_CONTENT));
        		cancelarBtn.setOnClickListener(cancelarClk);

Only cancelarBtn will be shown, and will take all the space. What am i doing wrong here?