title: set OnClickListener to LinearLayout in Navigation Drawer
body: <p>I have a Navigation Drawer in my activity that contain a LinearLayout and a ListView. Issue is When user click on Linear Layout, instead firing this view onClickListener, My Fragment onclickListener fired and wrong action happened!</p>
  
  <p><img src="https://i.stack.imgur.com/GR5zJ.png" alt="enter image description here"></p>
  
  <p>This is my Navigation Drawer XML File:</p>
  
  <pre><code>&lt;android.support.v4.widget.DrawerLayout
      xmlns:android="http://schemas.android.com/apk/res/android"
      android:id="@+id/drawer_layout"
      android:layout_width="match_parent"
      android:layout_height="match_parent" &gt;
  
      &lt;FrameLayout
          android:id="@+id/content_frame"
          android:layout_width="match_parent"
          android:layout_height="match_parent" &gt;
      &lt;/FrameLayout&gt;
  
      &lt;LinearLayout
          android:id="@+id/linearDrawer"
          android:layout_width="260dp"
          android:layout_height="match_parent"
          android:layout_gravity="right"
          android:background="#80ff0000"
          android:orientation="vertical" &gt;
  
          &lt;LinearLayout
              android:id="@+id/userContent"
              android:layout_width="260dp"
              android:layout_height="80dp"
              android:background="@android:color/black"
              android:gravity="center_vertical" &gt;
  
              &lt;RelativeLayout
                  android:id="@+id/userDrawer"
                  android:layout_width="match_parent"
                  android:layout_height="match_parent"
                  android:background="@color/transparent" &gt;
  
                  &lt;ImageView
                      android:id="@+id/ImgBackground"
                      android:layout_width="260dp"
                      android:layout_height="80dp"
                      android:layout_alignParentLeft="true"
                      android:layout_centerVertical="true"
                      android:contentDescription="@string/app_name"
                      android:scaleType="centerCrop"
                      android:src="@drawable/parsvid_view_video_image_placeholder" /&gt;
  
                  &lt;FrameLayout
                      android:id="@+id/avatar_holder"
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_alignParentRight="true"
                      android:layout_marginRight="13.5dp"
                      android:layout_marginTop="10dp" &gt;
  
                      &lt;com.meg7.widget.SvgImageView
                          android:id="@+id/avatar_strok"
                          android:layout_width="60.5dp"
                          android:layout_height="60.5dp"
                          android:scaleType="centerCrop"
                          android:src="#B3ffffff"
                          app:svg_raw_resource="@drawable/mask" /&gt;
  
                      &lt;com.meg7.widget.SvgImageView
                          android:id="@+id/user_avatar_logged"
                          android:layout_width="55.5dp"
                          android:layout_height="55.5dp"
                          android:layout_gravity="right"
                          android:layout_marginRight="2.5dp"
                          android:layout_marginTop="2.5dp"
                          android:scaleType="centerCrop"
                          android:src="@drawable/user_avatar"
                          app:svg_raw_resource="@drawable/mask" /&gt;
                  &lt;/FrameLayout&gt;
  
                  &lt;RelativeLayout
                      android:layout_width="wrap_content"
                      android:layout_height="wrap_content"
                      android:layout_marginRight="5dp"
                      android:layout_marginTop="20dp"
                      android:layout_toLeftOf="@+id/avatar_holder" &gt;
  
                      &lt;TextView
                          android:id="@+id/txt_user_name_drawer"
                          android:layout_width="fill_parent"
                          android:layout_height="wrap_content"
                          android:gravity="right"
                          android:text=""
                          android:textAllCaps="true"
                          android:textAppearance="?android:attr/textAppearanceMedium"
                          android:textColor="@android:color/white" /&gt;
  
                      &lt;TextView
                          android:id="@+id/txt_user_email"
                          android:layout_width="fill_parent"
                          android:layout_height="wrap_content"
                          android:layout_below="@+id/txt_user_name_drawer"
                          android:gravity="right"
                          android:text=""
                          android:textAllCaps="true"
                          android:textColor="@android:color/white"
                          android:textSize="12sp" /&gt;
                  &lt;/RelativeLayout&gt;
              &lt;/RelativeLayout&gt;
          &lt;/LinearLayout&gt;
  
          &lt;View
              android:id="@+id/viewSeparator"
              android:layout_width="match_parent"
              android:layout_height="1dp"
              android:background="#FFffbb00" /&gt;
  
          &lt;ListView
              android:id="@+id/drawer_list"
              android:layout_width="260dp"
              android:layout_height="match_parent"
              android:layout_gravity="right"
              android:background="#FF002bcc"
              android:cacheColorHint="@color/transparent"
              android:choiceMode="singleChoice"
              android:divider="@android:color/transparent"
              android:dividerHeight="1dp" /&gt;
      &lt;/LinearLayout&gt;
  &lt;/android.support.v4.widget.DrawerLayout&gt;
  </code></pre>
  
  <p>And my java code is:</p>
  
  <pre><code>LinearLayout mUserContent;
  mUserContent = (LinearLayout) findViewById(R.id.userContent);
  mUserContent.setClickable(true);
  mUserContent.setOnClickListener(new OnClickListener() {
  
      @Override
      public void onClick(View v) {
  
          Toast.makeText(getApplicationContext(), "Clicked!!", Toast.LENGTH_LONG).show();
  
          if(LoginSession.isLoggedIn()){
              // do something
          }else{
              // do another thing
          }
      }
  });
  </code></pre>
  
  <p>Where is the problem?</p>